Chrome redirects localhost to production

-1

I do not know if it's the right place to post this question, if I'm wrong please correct me.

Anyway, I'm trying to access my localhost/passagem and it redirects me to the production site.

I have tried to clean Cache with CTRL+F5 , SHIFT+CTRL+F5 and CTRL+R , and also the Hard Reload of Google Chrome. I have also tried to reinstall Chrome as well.

I followed the steps of the gringo Stack: link and it did not work either .

I did some testing, tried to access localhost over IP 127.0.0.1 and it worked, however, by 127.0.1.1 it redirects to production.

My hosts file (/ etc / hosts) has the following IP's:

127.0.0.1   localhost
127.0.1.1   rodoviario

I've tried to change 127.0.1.1 to 127.0.0.1 and road to localhost and I was not able to.

Does anyone have any idea why this happens?

    
asked by anonymous 17.08.2017 / 15:39

1 answer

0

I discovered the problem

In the header.php of my project there was a conditional that if the IP were not 127.0.0.1 it redirected to production.

It turns out that Chrome accesses localhost on IPv6 (:: 1) so it was redirecting.

    
18.08.2017 / 15:50