Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Atahualpa 3 Wordpress theme (http://forum.bytesforall.com/forumdisplay.php?f=2)
-   -   Not a theme problem...but need htaccess solution for duplicate posts (http://forum.bytesforall.com/showthread.php?t=11987)

Steve41 Jan 3, 2011 04:21 PM

Not a theme problem...but need htaccess solution for duplicate posts
 
For some reason, I've quite a number of posts showing 2 urls in Google Webmaster tools. e.g:
/this_is_a_post/1447/
/this_is_a_post/

My permalink structure is /%postname%/%post_id%/

This is my current htaccess

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

Both types of urls resolve, but to avoid duplicate issues and keep all my links resolvable, I want to 301 redirect all url requests that include the post_id, and just return the postname in the url i.e. /this_is_a_post/

Searched the web but haven't found a htaccess rule that quite works. Appreciate any help.

jankph Jan 6, 2011 01:58 AM

If "any" help is OK, and if "quite a number of posts" is manageable, my slowfix would be to use a Redirection plugin for the posts that appear twice.


All times are GMT -6. The time now is 05:29 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.