Reputation: 193
I have a web application successfully run on a server. I download the complete code from the server and install it on local machine with xampp on it.
When I run it on local server only the first login page is appear correctly, but as soon as I login with username and password there was error shown on the page like below.
Object not found!
The requested URL was not found on this server. The link on the referring page seems to be wrong or outdated. Please inform the author of that page about the error.
If you think this is a server error, please contact the webmaster.
Error 404
127.0.0.1
Apache/2.4.7 (Win32) OpenSSL/1.0.1e PHP/5.5.9
my url is like this 127.0.0.1/myproject
as soon as I login with username and password the url chnges to this one 127.0.0.1/myproject/user/login
and shows the error.
my default controller is user
and it is calling its index function
but when i call other function from the controller it always shows same error page.
the base url on the server is this http://192.168.10.170/cli/myfolder/project/myproject
which i change on my local machine is this http://127.0.0.1/myproject/
what is the problem over here I didn't understand. How can I run this on my local machine.
Upvotes: 1
Views: 1792
Reputation: 4456
This is caused by .htaccess
. So on local you can change the base url with a index.php?/
.
So your sample login page url will be like this.
127.0.0.1/myproject/index.php?/user/login
Upvotes: 1
Reputation: 100
Please check the .htaccess file in the myproject folder.
RewriteBase value needs to be changed based on your folder path in the local machine.
Upvotes: 0