Duplicate Page
-
I just Check Crawl the status error with Duplicate Page Content. As Mentioned Below.
Songs.pk | Download free mp3, Hindi Music, Indian Mp3 Songs
Songs.pk | Download free mp3, Hindi Music, Indian Mp3 Songs
http://getmp3songspk.com and then i added these lines to my htaccess file
RewriteBase /
RewriteCond %{HTTP_HOST} !^www.getmp3songspk.com$ [NC]
RewriteRule ^(.*)$ http://www.getmp3songspk.com/$1 [L,R=301]But Still See that error again when i crawl a new test.
-
Not sure what you want to achieve with these lines - but both url's are still accessible.
If you want to redirect www to non-www use this:
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} ^www.(.)$ [NC]
RewriteRule ^(.)$ http://%1/$1 [R=301,L](http://stackoverflow.com/questions/234723/generic-htaccess-redirect-www-to-non-www)
Other way round:
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www.
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L](http://stackoverflow.com/questions/12050590/redirect-non-www-to-www-in-htaccess)
Dirk
-
This post is deleted! -
Thanks For your Answer, So i understand the error and now give me a good htaccess code
i want getmp3songspk.com, getmp3songspk.com/ and www.getmp3songspk.com/ to redricet http://www.getmp3songspk.com So that i can avoid duplicate urls
Currently i have
RewriteCond %{HTTP_HOST} !^www.getmp3songspk.com$ [NC]
RewriteRule ^(.*)$ http://www.getmp3songspk.com/$1 [L,R=301]Suggest me a good code to avoid duplicate issue forever.
-
To remove the trailing slash - check http://stackoverflow.com/questions/21417263/htaccess-add-remove-trailing-slash-from-url & try one of the answers proposed there. Than add the 2 lines from the 2nd example in my first answer.
Dirk
-
Very Thanks to you Sir.