- 论坛徽章:
- 0
|
Apache目录列表模式定制个性化界面
谢谢
HQ老大.
我修改了我的一个叶面效果不错!
- Alias /ln_actions/ "/home/atest/pic/"
- <Directory "/home/atest/pic">;
- Options Indexes MultiViews
- # IndexOptions ScanHTMLTitles
- # IndexOptions HTMLTable
- # IndexOptions VersionSort
- # IndexOptions FoldersFirst
- IndexIgnore header.html footer.html bepc.jpg actions defects
- HeaderName /home/atest/pic/header.html
- ReadmeName /home/atest/pic/footer.html
- IndexOrderDefault Ascending Date
- ServerSignature Off
- DirectoryIndex index.htm
- AllowOverride None
- Order allow,deny
- Allow from all
- </Directory>;
复制代码
但当我想对apache发布的根目录加header 和 footer的时候总是不成功。
加的option都是一样的。为什么就不行呢?
- <Directory />;
- Options Indexes FollowSymLinks Includes MultiViews
- IndexIgnore header.html footer.html bepc.jpg actions defects
- HeaderName /home/atest/pic/header.html
- ReadmeName /home/atest/pic/footer.html
- IndexOrderDefault Ascending Date
- ServerSignature Off
- DirectoryIndex index.htm
- AllowOverride None
- Order allow,deny
- Allow from all
- </Directory>;
复制代码
不好意思!已经知道了!
是HeaderName和ReadmeName的位置。写的不对,应该是相对于http的根,而不是文件系统的根。
上边的那个之所以没有问题是因为做了alias同时文件系统的路径和http的路径一样,所以才没有问题。 8-)
无论如何谢谢HQ老大的分享! 8-) |
|