|
发表于 2013-3-11 13:35:01
|
显示全部楼层
2 S. D; W2 y& |* E) L, ]8 F
打开记事本,把下面代码粘贴进去:9 ~7 H7 ^' |0 l" H9 l
[ISAPI_Rewrite]6 @9 q( e8 G1 G
; Z8 n( [' U- U0 W# 3600 = 1 hour; k U) E/ L& p2 q( H5 Y5 M
3 M" x% d" X" ^" T8 lCacheClockRate 3600
3 A W7 }. x2 K, r4 N8 W E1 E2 p& s, f5 z, @6 _
RepeatLimit 32
% s) m7 A' \2 U/ r$ {/ X: G/ x+ b$ M" J' b. K0 ?7 E
# Protect httpd.ini and httpd.parse.errors files6 D+ ?4 t: I8 c4 G
3 Q `; ]/ m' N+ i9 d7 C" k# from accessing through HTTP
/ T+ J; z5 ^, X0 f
9 W/ \, p* h1 J6 f' y. m2 @# Rules to ensure that normal content gets through
* l3 b) c& w) C5 D7 d# p4 }% E( ^* d* `' ?9 b( [, h% z
RewriteRule /sitemap.xml /sitemap.xml [L]" ~ L1 }0 o5 ]! f, L- C
* I# \8 K% }, f% }. x3 {
RewriteRule /favicon.ico /favicon.ico [L]* }' j2 n, x* [7 B
0 y5 \5 ?5 {' ~4 {5 ?3 I4 [) L
# For file-based wordpress content (i.e. theme), admin, etc.. i, w% Y7 Z! m) y1 P
- \9 H3 k* O! [$ o2 n- D+ s8 bRewriteRule /wp-(.*) /wp-$1 [L]
9 \* ?8 N. M0 l
' q; }$ [% H: O% u. J, h# For normal wordpress content, via index.php
5 D1 A/ R- i+ P, Q$ u; A! `
/ {- m7 g, w6 l; _/ r- `1 [( FRewriteRule ^/$ /index.php [L]
- m2 d$ D4 X" b# H
! f1 g. w) L. gRewriteRule /(.*) /index.php/$1 [L]
: {' [6 p/ T& K" S6 ]" G
3 O& M8 i- z8 V' z' _. U保存时保存类型选择“所有文件”,并输入文件名称:httpd.ini. a ]/ Z e+ ~5 f
1 L" z7 F& `! y5 W将这个httpd.ini文件上传到WP程序所在的目录也就是与index.php在同一个目录内。
. ]6 C/ D8 q2 a7 c1 o- G7 g( Q2 u# @! e2 j6 s \$ m, R/ S
之后进入WP后台修改固定链接,比如:/%category%/%post_id%.html |
评分
-
查看全部评分
|