Link to home
Start Free TrialLog in
Avatar of stargateatlantis
stargateatlantis

asked on

Local host running wamp server

So lets say I am running a local host like wamp server.  Currently I am running UwAmp which is better then wamp.  http://www.uwamp.com/.  So i have modified my host file so that www.mydomain.com points to my local server.  But when i have no internet access even though i have my UwAmp server when i type www.mydomain.com the browser says you have no internet even though i have work offline check off.  How Do i fix this so that when I have no internet even though i type www.mydomain.com it will still access my local server.  I can always access localhost but anything that is pointed to my local server in my host file doesn't work unless i am connected to the internet.  Any ideas
Avatar of santoso-g
santoso-g

I assume you use Windows XP:
1. Please make sure you have static IP address for your PC, not dynamic from DHCP server.
2. You should use illegal IP addresses, such as 10.x.x.x, 172.16.x.x - 172.31.x.x, or 192.168.x.x
3. Can you provide the content of C:\Windows\System32\drivers\etc\hosts file? It should have the content of: 10.1.1.1 www.mydomain.com
where 10.1.1.1 (example only) is your local PC IP address.
4. Also try to ping www.mydomain.com using the Command Prompt. It should ping to your local IP address.
5. Please remove proxy settings within your web browser application, or at least use bypass proxy for local addresses.
Avatar of stargateatlantis

ASKER

The computer isn't connected to any type of network at all.  Its just a laptop with no internet access at all.  I just want to be able to access www.mydomain.com without any internet connection.  The host file uses the local IP of 127.0.0.1 and there is no proxy settings
Make sure that your web server listens to 127.0.0.1
Then, the content of C:\Windows\System32\drivers\etc\hosts file should contain the following line:
127.0.0.1 www.mydomain.com localhost
Please open Command Prompt and then type:
ping www.mydomain.com
It should have the following output:
Pinging www.mydomain.com [127.0.0.1] with 32 bytes of data:

Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128

Restart uwamp and then open IE or Firefox and type in the address:
www.mydomain.com

ASKER CERTIFIED SOLUTION
Avatar of mickey159
mickey159
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial