Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

a few months ago we set up canonical URLs for many page types such as http://www.wowhead.com/item=50362/deathbringers-will. This worked very well and google picked them all up.

A few days ago I implemented the same thing for blog posts but mysteriously it's not working.

<link rel="canonical" href="/blog=174055/cataclysm-beta-patch-build-13316" />

This blog post was written after my change but google shows www.wowhead.com/blog=174055 as the URL; any reason why? I can't really figure it out, the content of the pages is the same, and it's not really any different than what we did with /item and that worked.

share|improve this question
add comment

2 Answers

up vote 1 down vote accepted

Your root-relative canonical URL looks funny to me. I'm inclined to include your domain name there. Google says:

The rel="canonical" attribute can be used with relative or absolute links, but we recommend using absolute links to minimize potential confusion or difficulties. If your document specifies a base link, any relative links will be relative to that base link.

I would be hesitant to judge how Google is indexing until a good amount of time has passed. How old is that url?

share|improve this answer
1  
it happens on all NEW blog posts, even if they are only minutes old. We use relative paths for all other page types and it has always worked. –  Andreas Bonini Nov 18 '10 at 16:42
    
And have you tested using absolutely links for any posts? I'd say test that. –  artlung Nov 18 '10 at 16:46
    
I didn't and it would be very complex to do; since relative URLs work for all other page types I don't see why it would be the problem =( –  Andreas Bonini Nov 18 '10 at 16:56
    
Well, your answer to the problem is that Google is not working as expected. If you want to see if it might make a difference, you'll have to test it. :-| –  artlung Nov 18 '10 at 17:27
    
This seems to have worked; thanks. It's still very weird because pages like wowhead.com/item=2454 use and have always used relative URLs and always worked. :S –  Andreas Bonini Nov 21 '10 at 15:31
show 1 more comment

Using absolute versus relative URLs and giving it a bit of time should ... er, actually does work.

http://www.google.com/search?q=Cataclysm+Beta+Patch+%28Build+13316%29

Google is presenting your canonical URL.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.