interesting problem with accessing localhost index.html
Posted by: Jedi (---.dyn.iinet.net.au)
Date: February 20, 2012 05:58PM

Hi guys,

This isn't a huge problem as I'm just going to be developing on this machine, but I am a bit curious as to why it's happening.

I have placed my own index.html inside C:/wamp/www and if i navigate to localhost/index.html, this page loads. However, if I simply type 'localhost' into my browser it doesn't load my page but instead the familiar 'It Works!' default Apache page. It isn't accessing the index.html inside the htdocs directory of apache because I've edited that file and it doesn't get updated, and there is no other index page as far as I can find.

Just a weird error that I can't figure out. It doesn't really impede my development but unexplained things annoy me tongue sticking out smiley

Thanks

Options: ReplyQuote
Re: interesting problem with accessing localhost index.html
Posted by: stevenmartin99 (Moderator)
Date: February 20, 2012 06:02PM

Maybe you have another copy of apache installed??

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: interesting problem with accessing localhost index.html
Posted by: RiggsFolly (---.as13285.net)
Date: February 29, 2012 02:51AM

Have you changed your httpd.conf file?

DirectoryIndex index.php index.html index.htm

To something like

DirectoryIndex index.php

This would explain why when you just use localhost it runs the index.php and not the index.html

Options: ReplyQuote
Re: interesting problem with accessing localhost index.html
Posted by: Jedi (---.dyn.iinet.net.au)
Date: March 06, 2012 06:11PM

Hi everyone,

I am no longer getting this problem. I beleive that it was as stevenmartin had said and I had somehow managed to confuse apache by having multiple installs (I had never set up a development environment before, and tried to manually install Apache and PHP before I discovered wamp).

After a reboot and restarting wamp manually it looks like everything is fixed. I couldn't see two versions of apache running before or anything, but it does appear to have fixed it.

For the purposes of tying up loose ends I hadn't modified the DirectoryIndex.

Hopefully this thread becomes an answer for someone looking now (I hate it when people ask a question but never the answer.)

Thanks for all your help

Options: ReplyQuote


Sorry, only registered users may post in this forum.