Tuesday, 15 September 2015

Urls indexed in Google with index.php, Laravel configured to not use it in paths -


I recently created a small website created with the latest Laravel. All is well, URL reconstruction is included.

But I noticed that Google has indexed some URLs from path to index.php . As you know, this could cause a duplicate content problem.

I checked triple, and when you browse the website there is no way to access a URL with index.php . So I wonder how to stop the framework to load the URL with index.php , or at least one URL to the correct URL in the index.php Redirect without. / P>

In the original htaccess, I only added it to force www in the URL:

  RewityCand% {HTTP_HOST} ^ domain \ .com [nc] rewritable ^ ( . *) $ Http://www.domain.com/ [L, R = 301]   

I do not think this is the cause of this problem, but I mention it, Bus .

Thank you.

This is what works for me, to help me from Laravel URL Index.php :

  rewrite% {THE_REQUEST} ^ GET. * Index .php [NC] rewrite (. *?) Index \ .php /*(.*) / $ 1 $ 2 [R = 301, NE, L]    < / Html>

No comments:

Post a Comment