简体   繁体   English

Codeigniter本地主机重定向到实时服务器

[英]Codeigniter local host redirects to live server

I downloaded the source code of a website. 我下载了网站的源代码。 The website is live and working. 该网站正在运行中。 I wanted to make some changes offline to test them first but when I go to localhost on my browser, I get redirected to live website and the changes are not being updated. 我想先离线进行一些更改以测试它们,但是当我在浏览器中转到localhost时,我被重定向到实时网站,并且更改未得到更新。 Help me with this. 帮帮我

application/config/config.php页面中,更改base url

$config['base_url'] = 'http://localhost/yourfoldername/';

Its probably 它可能

 $config['base_url']

You can find it in 你可以在找到它

application/config/config.php application / config / config.php

If that doesnt work, check out the .htaccess file and try to comment out rows that have Redirect in them. 如果那不起作用,请签出.htaccess文件,并尝试注释掉其中包含重定向的行。

You can find more info on redirecting in htaccess here 您可以在此处找到有关htaccess中重定向的更多信息

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM