Page 1 of 1

xampp working but can't open localhost

PostPosted: 31. July 2011 22:23
by robin4321
hello,
i installed xampp few years ago and it worked all fine. today i opened one file on C: disk
windows > system32 > drivers > etc > hosts
i changed there first lines (added some web address) and after few minutes deleted so everything looks like it was before
The problem is that now, i can run xampp (see picture-> http://imageshack.us/photo/my-images/828/yampp.png) but cannot open localhost.
what should i do, can i solve this problem somehow

Re: xampp working but can't open localhost

PostPosted: 01. August 2011 01:25
by Sharley
It would have been more help if you had pasted the hosts file content in your post.

Make sure that the first line after the comments in your hosts file looks like this
Code: Select all
127.0.0.1        localhost

Re: xampp working but can't open localhost

PostPosted: 01. August 2011 09:20
by robin4321
after entering this line (127.0.0.1 localhost) i get the same result.
here is a screenshot of hosts file http://imageshack.us/photo/my-images/836/xamppo.png/, and screenshot of localhost page in browser http://imageshack.us/photo/my-images/713/xampp1.png/

Re: xampp working but can't open localhost

PostPosted: 01. August 2011 12:52
by Sharley
You have a 404 file not found error so read the C:\xampp\apache\logs\error.log file for clues.

Re: xampp working but can't open localhost

PostPosted: 01. August 2011 23:05
by robin4321
i checked and here is one line:
[Mon Aug 01 10:10:25 2011] [error] [client 127.0.0.1] File does not exist: D:/programi/xampp/xampplite/htdocs/xampp

i don't know what is missing there, didn't delete anything and it worked before

Re: xampp working but can't open localhost

PostPosted: 02. August 2011 01:52
by Sharley
robin4321 wrote:File does not exist: D:/programi/xampp/xampplite/htdocs/xampp
I think the error is quite clear, Apache can't find the file you requested in your browser's address bar in the folder the request specified.

What are you typing in your browser's address bar when you get this error?

What do you see in your browser when you just type http://localhost in the address bar?

Re: xampp working but can't open localhost

PostPosted: 02. August 2011 07:29
by robin4321

Re: xampp working but can't open localhost

PostPosted: 02. August 2011 07:42
by robin4321
hey sharley, i just entered some other "deep linking" URLs (some projects that i have on my computer in /htdocs/ folder) and they worked (i should have tested that before).
i can't open xampp "homepage" only, but other pages in /htdocs/ folder work properly.
i'll see what file is missing and why i can't open localhost homepage, big thanks for your help