Originally posted by kirilisa
I am running apache 2, php 4.3, and mysql 4.1 on windows XP. I have noticed that when I view my php pages via locahost (http://localhost/hockey_list/initial.php) they display just fine, but when I view them using my machines domain name (http://squelch.tzo.com/hockey_list/initial.php) the page flashes for a brief moment and then, as if redirecting, brings me to the "Page cannot be displayed" IE error page.
This has only been happenning for the past few days. I reinstalled apache, php, and mysql to no avail.
Even if the script is as simple as the phpinfo script which just has
<? phpinfo(); ?>
in it, it won't work.
I guess this would suggest some sort of apache config problem? but I didn't change anything in apache recently so I am puzzled.
Incidentally, my domain name isn't quite 'real' as it is a tzo.com forward (my machine is behind a cable modem and therefore has dynamic IP which Tzo's service gets around).
1. Do you have Virtualhost entry in your httpd.conf?
2. Do you have domain name entry in your c:\winnt\system32\drivers\etc\hosts?
3. Or if you are using DNS, is there (in DNS) entry for that domain name?
My script is viewing fine right now but as it is also viewing fine when I take away the stuff in hosts and httpd.conf, I don't know whether it is actually fixed or whether it is just being intermittant again...
Please help. This is really strange. Apache and php. phpinfo() seem to work fine in localhost. But when it's on Virtualhost it doesn't seem to work. It only work for other browser like firefox mozilla.