Welcome to MLink Developer Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
295 views
in Technique[技术] by (71.8m points)

服务器的路由配置问题

现在需要实现如下的目录结构。
每个页面都有单独的文件夹,并且包含私有的图片、样式等资源,页面的引用使用相对目录。
比如:<img src="images/logo.png">
静态文件目录存放公共的资源,页面的引用使用相对域名的目录。
比如:<img src="/assets/images/logo.png">
假设域名是localhost,实现是apache,当然有其他服务器的解决办法也能参考。
要求浏览器输入localhost后正确打开index.html。

  • assets(静态文件目录)

    • images

    • scripts

    • fonts

    • others

  • pages(页面文件目录)

    • index

      • index.css

      • index.js

      • index.html

    • login

      • login.css

      • login.js

      • login.html


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
等待大神答复

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to MLink Developer Q&A Community for programmer and developer-Open, Learning and Share
...