我在 Windows 7(测试版)上打开 http://localhost/ 时遇到了大问题.我安装了这个操作系统,一切都很好;当我安装 Wamp 时,我看到 localhost 根本不起作用.我只看到这个错误:
I have a big problem opening http://localhost/ on Windows 7 (beta). I installed this os and everything went great; when I installed Wamp I saw that localhost is not working at all. I just see this error:
Firefox 无法与 localhost 上的服务器建立连接.
Failed to Connect
Firefox can't establish a connection to the server at localhost.
在 Mozilla 和资源管理器中.
in Mozilla and Explorer.
我删除了 Wamp,几周后(这意味着从今天起两周)我在 Windows 7 上安装了 NetBeans.我创建了一个测试 PHP 脚本,当我调试它时,我再次遇到相同的错误.我试图用 ip 127 访问它......但还是一样.有什么问题?
当我安装 NetBeans 时,我将其安装在 8080 端口.
I removed Wamp and after some weeks (that means two weeks from today) I installed NetBeans on Windows 7. I created a test PHP script and when I debug it, I get the same error again. I tried to access it with ip 127.... but still the same. What is the problem?
When i installed NetBeans I installed it in port 8080.
要解决 80 端口问题,请执行以下操作:
To fix the port 80 problem do:
从 cmd 以管理员身份:
From cmd as administrator:
sc config http start= demand
(你需要在等号之后而不是之前有一个空格)netsh http show servicestate
) 以检查端口 80 是否正在使用中sc config http start= demand
(you need a space after the equal sign and not before)netsh http show servicestate
) as administrator to check that the port 80 is in use运行此命令后,您可以禁用http.sys,如下所示:
After you have run this command, you can disable http.sys as follows:
net stop http
(停止进程)Sc config http start= disabled
(如果你想永久禁用该服务)net stop http
(stop the process)Sc config http start= disabled
(if you want to disable the service forever)它对我有用.
这篇关于http://localhost/在 Windows 7 上不工作.有什么问题?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!