R=301 This means the redirect is 301 (permanent) and this is useful for search engines when you change the domain or change a whole directory. L This means that this is the last rule (if matched). So, if the URL matches this rule, do not go any further in the htaccess file.
let me try to explain it :- i have this url indexed in google www.site.com/temp1_pages.php what i want , if a user types www.site.com/temp/pages/1 it should open www.site.com/temp1_pages.php .. so i have used [L] for this... but still my old link is indexed in google which i want to change to newer one.. any help is really appreciated..
1. L is not the key! R=301 is. Show me the htaccess file please. 2. In order to remove the old URL from google, you must remove or change all links that point to it.
RewriteRule ^privacy-policy.html$ /privacy_policy.php [L] this rule says if you ask www.site.com/privacy-policy.html, if will give you www.site.com/privacy_policy.php, but still show www.site.com/privacy-policy.html in the browser (although privacy-policy.html doesn't exists) which is correct... the trouble part is previously google has indexed privacy_policy.php..... now i want if crawler comes next time to my site it should replace privacy_policy.php with privacy-policy.html....i.e. it should index www.site.com/privacy-policy.html instead of www.site.com/privacy_policy.php (although privacy-policy.html doesn't exists).... hope i am clear...
hey thanks for all your help.. so is this the only solution ?? reason i am asking is because my site get a lot of traffic daily by google... one more thing, if needed to remove, how will i remove site from google's index ? log-in into google-webmaster and request for remove site ??? thanks again. you'v been very helpful..