What is the best way to handle these duplicate page content errors?
-
MOZ reports these as duplicate page content errors and I'm not sure the best way to handle it.
Home
http://myhjhome.com/
http://myhjhome.com/index.phpBlog
http://myhjhome.com/blog/
http://myhjhome.com/blog/?author=1Should I just create 301 redirects for these?
- 301 http://myhjhome.com/index.php to http://myhjhome.com/ ?
- 301 http://myhjhome.com/blog/?author=1 to http://myhjhome.com/ ?
Or is there a better way to handle this type of duplicate page content errors?
and
-
Hi Joseph,
You can handle both of these issues pretty easily:
Home - you can redirect /index.php with a few simple lines in your site's .htaccess file:
RewriteBase /
RewriteRule ^index.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]However, instead of adding these lines manually, you can simply turn on "Pretty Permalinks" in WordPress (see http://codex.wordpress.org/Using_Permalinks for more details), and they should get added automatically.
Blog - since you're using WordPress, I recommend installing Yoast's SEO plugin (it's free - http://yoast.com/wordpress/seo/). Then, you can correct the ?author=1 issue by disabling author archives. Here's a quick reference for other functionality offered by the plugin: http://yoast.com/articles/wordpress-seo/
I hope that helps!
Cheers,
Steve -
You can just add a canonical url tag.
http://moz.com/blog/canonical-url-tag-the-most-important-advancement-in-seo-practices-since-sitemaps