本文介紹了當我嘗試通過 `http://localhost/xampp/htdocs/index.html` 打開 HTML 文件時,它說無法連接到 localhost的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!
問題描述
我已經安裝了 XAMPP,有一個 htdocs
文件夾,里面有 index.html
文件,當我嘗試通過 http://localhost/xampp/htdocs/index.html
在瀏覽器中打開它時,它說無法連接到本地主機.
I have installed XAMPP , there is a htdocs
folder and inside it index.html
file ,
when I try to open it in my browser through http://localhost/xampp/htdocs/index.html
it says
unable to connect to localhost .
怎么了?
推薦答案
代替
http://localhost/xampp/htdocs/index.html
試一試
http://localhost/index.html
或者如果 index.html 保存在 htdocs 的文件夾中,那么
or if index.html is saved in a folder in htdocs then
http://localhost/<folder-name>/index.html
這篇關于當我嘗試通過 `http://localhost/xampp/htdocs/index.html` 打開 HTML 文件時,它說無法連接到 localhost的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!
【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!