括号实时预览错误“页面不是当前项目的一部分”
Brackets Live Preview Error " Page is not part of the current project"
我在 MAMP 上的文档根目录是 C:\MAMP\htdocs
实时预览基础 URL 是 https://localhost/
以前,当我单击 "File"-->"Open.." 并选择一个 html 文件时,实时预览确实有效,但现在我单击 "File"- ->"Open Folder" 选择了 htdocs 并点击了同一个 html 文件,Brackets 上的消息显示为 "Live preview was cancelled because the browser navigated to a page that is not part of the current project." Google Chrome 只是说 "localhost refused to connect." 我试过了打开一个新文件并尝试实时预览,但同样的事情发生了。我做错了什么吗?在我打开文件夹之前,实时预览肯定可以正常工作...
好的,所以我将所有 html 文件分组到一个文件夹中,单击 "file-->open folder" 并选择包含所有 html、css 和图像的文件夹,然后单击我的 html 文件之一,实时预览效果很好。不明白整个项目是如何运作的,但现在我明白了。
我在 MAMP 上的文档根目录是 C:\MAMP\htdocs
实时预览基础 URL 是 https://localhost/
以前,当我单击 "File"-->"Open.." 并选择一个 html 文件时,实时预览确实有效,但现在我单击 "File"- ->"Open Folder" 选择了 htdocs 并点击了同一个 html 文件,Brackets 上的消息显示为 "Live preview was cancelled because the browser navigated to a page that is not part of the current project." Google Chrome 只是说 "localhost refused to connect." 我试过了打开一个新文件并尝试实时预览,但同样的事情发生了。我做错了什么吗?在我打开文件夹之前,实时预览肯定可以正常工作...
好的,所以我将所有 html 文件分组到一个文件夹中,单击 "file-->open folder" 并选择包含所有 html、css 和图像的文件夹,然后单击我的 html 文件之一,实时预览效果很好。不明白整个项目是如何运作的,但现在我明白了。