简体   繁体   中英

localhost in WAMP not working

i use WAMP 2.2. installed and the ison is green. problem is the , when I enter locahost in URL , it doesn't work but when I enter 127.0.0.1 it works.

what is the reason ?

Chances are that either:

A. Your Windows Hosts file does not have this entry:

127.0.0.1 localhost

B. Or this entry is 1st (comes before the above), and Apache is Listening on IPv4 only:

::1 localhost

In the second case, just remove or comment out the entry.

Hosts file path:

C:Windows\system32\drivers\etc\hosts

You'll need to edit Hosts file via 'Run as admin' on Notepad.

You must be using windows 8. Please follow this guide to fix your wamp in Windows 8

How to run WAMP Server on Windows 8

Downgrading to Windows 7 is not a bad option if you are a regular developer.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM