I have two sites, one old, one new. The old one is not updated with new content but the new one uses reviews and other content that is naturally enough regarded by Google as duplicate content, so I want to either 301 the old site or rel=canonical to the new site...
... but the old site is an old CMS and the meta fields are keywords, description, and that'a about it and I don't think I have a way of writing between the <head> tags.
I'm not sure I want to kill off the old site with a 301, so I'd like to set canonical links in htaccess, but typically htaccess is used for .pdf to html domain links and not cross domain html to html, so I can't find a How To.
Any help welcome, thanks.
Canonicalization has nothing to do with one site to another. It's has to do with multiple ways of navigating to a site. My write up here explains it all. http://www.websitecodetutorials.com/code/htaccess/canonicalization-htaccess-mod_rewrite-301-redirect-non-www-to-www-and-index-to-folder.php. If you want a 301 redirect its under htaccess in my site
Cross site canonicalisation is observed by Google.
I think I need a version of the HTTP code from this blog post "How To: Advanced rel="canonical" HTTP Headers"
This is how to do a pdf to html rel=canonical in htaccess (I think).
Header set Link ‘<http://makeitrank.com>; rel=”canonical”‘
But I expect I would need to change "filesmatch" to something else...?
The tag you put in your head as far as I know does the same thing that a 301 redirect does in your htaccess. Matt talks about it in the video in my link above. So from the sounds of it you should 301 redirect in your htaccess
As I said in my first post, I can't add anything to the head. And I don't want to 301 as I'm reluctant to kill the domain off completely.
Oh I see what your saying. The PDF is the same content so don't split the seo. Yes I've read about that. I don't know how to deal with it though.
Flexing my google skills...
Yeah, what I'm trying to is...
Head set Link <http://www.new.com/wants-original-kudos>; rel="canonical"
I know that code, it's the same as in a link I posted above, I just wonder if it's any different I would need to do for an html file rather than a pdf.
I see no reason why PDF would be different
Most of the pages are .html but I also have a few "index.php?searchStr=&_a=view" pages
On WAMP I've created an htaccess with nothing in it except for:
Header add Link '<http://www.example.html>; rel="canonical"'
but visitiing http://localhost gives me a "500 Internal Server Error"
If I delete it from htaccess, localhost is fine.
Yeah htaccess does not work out of the box in wamp. Will give that error
This topic is now closed. New replies are no longer allowed.