|
|
发表于 2013-3-11 13:35:01
|
显示全部楼层
( p0 S. b3 j" j. q2 b/ v! _" s& i, j
打开记事本,把下面代码粘贴进去:; {2 J; u; m: N4 f8 s7 W3 v
[ISAPI_Rewrite]/ B, b \7 g# R- p% R' F" ?
) D" Z3 U$ S5 t6 Y
# 3600 = 1 hour
C+ \" w6 z" W( T: x% I h* ~, {* g" r) c' q+ ^0 g
CacheClockRate 3600! Q. g W9 {& z; G! J/ A. y. ^2 a4 s
: g. G3 a+ Z* y1 n6 ]" e0 X; aRepeatLimit 32
( H2 D/ \0 h. P5 y# \" T9 T* {& G+ q" `7 o
# Protect httpd.ini and httpd.parse.errors files- l2 L1 Z. ] w: c* w
z% m; s2 L# r$ h
# from accessing through HTTP
/ l' ]5 b# i2 I0 k8 R4 W4 s$ l! v( |6 F
# Rules to ensure that normal content gets through) O6 M) t0 i/ f( Z; Z, y% [; x+ V
1 P9 L4 S6 K5 N/ L! z+ u' yRewriteRule /sitemap.xml /sitemap.xml [L]
$ {* l: t5 F- Z7 o/ G& D, J" F: k r4 k
RewriteRule /favicon.ico /favicon.ico [L]
. [+ x! f/ ?* K8 m+ p H. D8 G+ [3 q: |3 c
# For file-based wordpress content (i.e. theme), admin, etc.' d* \& t8 S1 V/ x$ c6 H, r* e
) N0 N) l% _6 ]* A: p1 T
RewriteRule /wp-(.*) /wp-$1 [L]
6 H* f8 C) s: U# v2 P/ H
% `7 u0 l o4 E) _- g( S# For normal wordpress content, via index.php
6 R. q- a# } O" L, R2 O# ~% e3 |% u! _3 o( Q7 @7 m
RewriteRule ^/$ /index.php [L]( K p& Y- _# m; e3 T2 |, [
: F" \0 b7 G; h
RewriteRule /(.*) /index.php/$1 [L]
( w- ]1 b# I& M/ A* M
+ \3 U ~0 h. w: D4 g保存时保存类型选择“所有文件”,并输入文件名称:httpd.ini9 X: m) ?& F0 | M
- K- N. e% Q4 k3 J. Q2 i
将这个httpd.ini文件上传到WP程序所在的目录也就是与index.php在同一个目录内。% }% E' J% }) ~# }
: Q5 u- X$ R; r
之后进入WP后台修改固定链接,比如:/%category%/%post_id%.html |
评分
-
查看全部评分
|