wordpress在lighttpd下的重写规则及注意细节
<p><span style='font-family: tahoma, arial, "Microsoft YaHei"; font-size: 14px;'>wordpress博客是使用人数最多的一个开源博客程序,静态化也是最多人像要到的问题,对于新手来收,静态化的处理可能有点困难,有些空间需要使用静态插件来达到,但其实很多空间是不需要插件来静态化的,能重写url规则就开源达到静态化的处理了。好,下面看看。lighttpd下的重写规则。如果你是用lighttpd,那么就进入kloxo-》域名-》你的域名-》lighttpd重写规则: </span></p>
<div style='margin: 3px auto 0px; padding: 0px 3px; outline: none; line-height: 21.6px; clear: both; border-width: 1px; border-style: solid; border-color: rgb(0, 153, 204); background: rgb(246, 251, 255); overflow: hidden; font-family: tahoma, arial, "Microsoft YaHei";'>
<p style="margin: 0px; padding: 0px; outline: none; float: right; line-height: 25.2px; font-size: 14px;">
<span style="line-height: 25.2px; cursor: pointer;"><u>复制代码</u></span></p>
<p>
代码如下:</p>
</div>
<p style='margin: 0px auto 3px; padding: 0px 3px; outline: none; line-height: 25.2px; font-size: 14px; clear: both; border-right: 1px solid rgb(0, 153, 204); background: rgb(221, 237, 251); overflow: hidden; border-left: 1px solid rgb(0, 153, 204); word-break: break-all; border-bottom: 1px solid rgb(0, 153, 204); word-wrap: break-word; font-family: tahoma, arial, "Microsoft YaHei";'>
<br>
url.rewrite = ( <br>
“^/(wp-.+).*/?” => “$0″, <br>
“^/(sitemap.xml)” => “$0″, <br>
“^/(xmlrpc.php)” => “$0″, <br>
“^/(.+)/?$” => “/blog/index.php/$1″ <br>
) </p>
<p>
<br style='font-family: tahoma, arial, "Microsoft YaHei"; font-size: 14px;'><span style='font-family: tahoma, arial, "Microsoft YaHei"; font-size: 14px;'>注意如果安装目录在blog二级目录的下面的代码,如二级目录文件夹名为blog,那么规则即: </span></p>
<div style='margin: 3px auto 0px; padding: 0px 3px; outline: none; line-height: 21.6px; clear: both; border-width: 1px; border-style: solid; border-color: rgb(0, 153, 204); background: rgb(246, 251, 255); overflow: hidden; font-family: tahoma, arial, "Microsoft YaHei";'>
<p style="margin: 0px; padding: 0px; outline: none; float: right; line-height: 25.2px; font-size: 14px;">
<span style="line-height: 25.2px; cursor: pointer;"><u>复制代码</u></span></p>
<p>
代码如下:</p>
</div>
<p style='margin: 0px auto 3px; padding: 0px 3px; outline: none; line-height: 25.2px; font-size: 14px; clear: both; border-right: 1px solid rgb(0, 153, 204); background: rgb(221, 237, 251); overflow: hidden; border-left: 1px solid rgb(0, 153, 204); word-break: break-all; border-bottom: 1px solid rgb(0, 153, 204); word-wrap: break-word; font-family: tahoma, arial, "Microsoft YaHei";'>
<br>
url.rewrite = ( <br>
“^/blog/(wp-.+).*/?” => “$0″, <br>
“^/blog/(sitemap.xml)” => “$0″, <br>
“^/blog/(xmlrpc.php)” => “$0″, <br>
“^/blog/(.+)/?$” => “/blog/index.php/$1″ <br>
) </p>
頁:
[1]