Forum Moderators: open
Jim
IMHO, it's less productive and more "risky" to rely on back-end processing by the various search engines than it is to put your server in order from the outset. For example, I haven't even considered using the new canonical-URL tag, because it is impossible to fetch content from a non-canonical URL of any kind from any of my servers; From the moment a new site goes on-line, any non-canonical request gets redirected to the canonical URL with one single 301 redirect. So, I simply don't have to worry about whether the various search engines "get it right" when processing these proprietary fix-ups -- ever. YMMV.
Jim
From the moment a new site goes on-line, any non-canonical request gets redirected to the canonical URL with one single 301 redirect
Sure, and cookies would allow you to do that, because only 1 URL would serve that content.
But if you want to use SessionIDs, there is multiple URLs live on the site, all serving the same content.
The canonical tag would be the simplest implementation with least scope to go wrong. You could even dynamically serve it, using a script to stip the sessionID on-the-fly.
The 'correct' way would be your original suggestion, using user-agent detection to serve different URL forms to bots and non-bots, but that has far more opportunity to go wrong if badly implemented.
On a URL that looks like this:
http://www.example.com/subdir/page1?id=00000000001
you need
<link rel="canonical" href="http://www.example.com/subdir/page1" />
It might get a bit complicated if you have content-adjusting variable such as
http://www.example.com/subdir/page1?ContentModifier=1&id=00000000001
You would then need
<link rel="canonical" href="http://www.example.com/subdir/page1?ContentModifier=1" />
You might be best implementing a script that dynamically inserts the tag (minus the ID= string) into the header as the page is served.
[edited by: Shaddows at 3:03 pm (utc) on Mar. 9, 2009]
Say you have
www.example.com/page
It serves the same content as
www.example.com/page?ReferTrack=a01a
And the same content but different order to
www.example.com/page?ReferTrack=b01b&ListOrder=1
Which is in turn PRECISELY identical to
www.example.com/page?ListOrder=1&ReferTrack=b01b
All these will have different backlinks, all with split PR. There are better ways of dealing with the problem, but if you use the canonical tag, each would contain
<link rel="canonical" href="http://www.example.com/page" />
For blog software that will accept infinite "keyword" subdirectories, you can also insert a tag for the preferred "friendly" one.
What you really don't want to be doing is serving the same content at different URLs and saying "look, this was here first"
From my perspective I would implement the tag but if a given page is important, I'd still look to use redirects. Currently the impression I'm getting is that the SEs are treat the tag like the robots.txt file rather than a command.