
为什么80%的码农都做不了架构师?>>>
# wget
# tar -xzvf master
# wget .4.
# tar -xzvf nginx-1.4.
# cd nginx-1.4.2
# ./configure --prefix=/usr/local/nginx-1.4.2 --add-module=../ngx-fancyindex-ngx-fancyindex
# make
# make install server {
listen 80;server_name lsa;access_log /data/logs/lsa.access.log main;
index index.html index.php index.html;root /data/lsa;
location / {
}location ~ ^/2589(/.*){fancyindex on;fancyindex_exact_size off;fancyindex_localtime on;fancyindex_footer "myfooter.shtml";}} 看看nginx加了fancy的效果,如下图. [caption id="attachment_2615" align="alignnone" width="560"] fancy+fancy[/caption] 对比一下nginx内置的index效果(上篇文章贴过来的图),如下 [caption id="attachment_2590" align="alignnone" width="699"] nginx auto_index索引效果图[/caption] 参数解释: fancyindex on:开启fancy索引 fancyindex_exact_size off:不使用精确的大小,使用四舍五入,1.9M会显示为2M这样.如果开启的话,单位为字节 fancyindex_localtime on:使用本地时间 fancyindex_footer "myfooter.shtml":把当前路径下的myfooter.shtml内容作为底部.文件不存在底部会出现404 myfooter.shtml内容如下: <!-- footer START --><div id="footer"><a id="gotop" href="#" onclick=Top();return false;">回到顶部</a><a id="powered" href="/">WordPress</a><div id="copyright">版权所有 © 2011-2013 运维生存时间 </div><div id="themeinfo"><a href="/">关于我们</a> | <a href=".html">网站导航</a> | <a href=".xml">网站地图</a> |<a rel="nofollow" href="/">闽ICP备11007147号-1</a></div></div><!-- footer END --> 转载于:
本文发布于:2024-03-11 16:14:30,感谢您对本站的认可!
本文链接:https://www.4u4v.net/it/1710556992142266.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
| 留言与评论(共有 0 条评论) |