得到一个错误,当我访问http://本地主机 [英] Getting an error when I visit http://localhost

查看:106
本文介绍了得到一个错误,当我访问http://本地主机的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图通过对Chrome浏览器我的XAMPP本地主机访问,但我收到此错误信息:

I am trying to access localhost on my xampp via the Chrome browser but I get this error message:

Object not found!

The requested URL was not found on this server. If you entered the 
URL manually please check your spelling and try again.

If you think this is a server error, please contact the webmaster.

Error 404

Apache和MySQL被打开,所以我不明白。

Apache and MySQL are turned on so I don't understand.

推荐答案

您可以访问localhost的就好了。

You can access "localhost" just fine.

在404:未找到文件。错误表示一旦你的连接的服务器无法找到所请求的文件的为localhost

The "404: file not found" error indicates the server can't find the requested file once you've connected to localhost.

附录:

也许尝试之一来创建一个称为test.html一个普通的HTML文件
  您的虚拟主机不工作。随后尝试访问该网址。那
  应该给你一些线索可能是什么问题。 - Gohn67

Maybe try to create a regular html file called test.html in one of your vhosts that is not working. Then try to visit that url. That should give you some clue as to what may be the problem. – Gohn67

这是很好的建议。尝试一下。具体做法是:

This is good advice. Try it. Specifically:

1)创建以下五个文件:

1) Create the following five files:


  • C:/xampp/htdocs/dummy-host.localhost/test.html

  • C:/xampp/htdocs/dummy-host.localhost/test.html

C:/xampp/htdocs/my/test.html

C:/xampp/htdocs/my/test.html

C:/xampp/htdocs/launcher/public_html/test.html

C:/xampp/htdocs/launcher/public_html/test.html

C:/xampp/htdocs/website/httpdocs/test.html

C:/xampp/htdocs/website/httpdocs/test.html

C:/xampp/htdocs/my/test.html

C:/xampp/htdocs/my/test.html

2)确保每个目录下存在,每个人都有一个test.html的在它的Testing 1 ... 2 ... 3

2) Make sure each of these directories exist, and each has a "test.html" with the words "TESTING 1...2...3" in it

3)尝试这五个网址,在浏览器中:

3) Try each of these five URLs in your browser:

  • http://localhost/test.html
  • http://itutormaths.web/test.html
  • http://itutormaths.mod/test.html
  • http://itutormaths.hub/test.html
  • http://my.itm/test.html

4)报告回来,你从每个浏览器的URL得到确切的错误

4) Report back the exact error you get from each browser URL

这篇关于得到一个错误,当我访问http://本地主机的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆