52AV手機A片王|52AV.ONE

標題: discuz x3.2的SEO設定 [打印本頁]

作者: IT_man    時間: 2014-12-24 11:31
標題: discuz x3.2的SEO設定
本帖最後由 IT_man 於 2014-12-25 11:19 編輯 ; G( D2 H1 y" `2 k$ P7 G
1 u  M* u6 @# b. W% e
在此分為「Host server設定」Discuz 後台設定
  [* c& C3 |2 f6 z: ]
Host server設定】    又分為Web server站台根目錄下的.htaccess
$ `+ _' Y, |5 ?! D
  
Web server    註:有個地方須注意,/etc/httpd/conf/httpd.conf中<Directory "/www/coav4u/test"> 的 AllowOverride 一定要all,.htaccess才有作用: p# B- K4 n6 Y6 Z

- o+ P7 E4 I. C9 S$ L 站台根目錄下的.htaccess
  1. # -FrontPage-) _$ B+ u+ C& J8 b' H
  2. IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti*  
    $ L- k: P; F# ]( Z
  3. # disable directory browsing6 y) n. h8 C+ e) `% `6 K
  4.   Options All -Indexes& ~& P3 }- J: j9 C# ~! J4 }& s
  5. RewriteEngine On    # 將 RewriteEngine 模式打開; i3 M0 x( R3 {6 W: s6 ]  I/ C8 v
  6. RewriteBase /    #設定為網站的根目錄% H4 K) j$ p* l; G% N# [
  7. #$ X3 r8 U6 ~' r: F$ m
  8. RewriteCond %{HTTP_HOST} ^av4u.info [NC]
    ( p; r* x& M5 m1 Z4 Y, }
  9. RewriteRule ^(.*)$ HTTP://www.av4u.info/$1 [L]<font face="楷體,標楷體"><font size="3">RewriteRule ^topic-(.+)\.html$ portal.php?mod=topic&topic=$1&%1/ x' ~/ s, w# Q/ Y) n; ]7 {
  10. RewriteRule ^article-([0-9]+)-([0-9]+)\.html$ portal.php?mod=view&aid=$1&page=$2&%1% p! }! \3 u5 @+ I  @7 d* R
  11. RewriteRule ^forum-(\w+)-([0-9]+)\.html$ forum.php?mod=forumdisplay&fid=$1&page=$2&%1- _4 R' ^8 j4 l: |+ S( F
  12. RewriteRule
    ( R6 ]& ^) |; q
  13. ^thread-([0-9]+)-([0-9]+)-([0-9]+)\.html$ ( v4 e/ A+ \. _4 |
  14. forum.php?mod=viewthread&tid=$1&extra=page\%3D$3&page=$2&%1
    3 H  k) s+ d$ K  ~6 [% r, Y
  15. RewriteRule ^group-([0-9]+)-([0-9]+)\.html$ forum.php?mod=group&fid=$1&page=$2&%1
    , Z+ w) z. j# O' I% }
  16. RewriteRule ^space-(username|uid)-(.+)\.html$ home.php?mod=space&$1=$2&%1
    - S7 ~5 o4 P# z$ H6 J0 u/ f
  17. RewriteRule ^blog-([0-9]+)-([0-9]+)\.html$ home.php?mod=space&uid=$1&do=blog&id=$2&%1" x: H& J) o! @* I# O1 N3 b3 r
  18. RewriteRule ^archiver/(fid|tid)-([0-9]+)\.html$ archiver/index.php?action=$1&value=$2&%1</font></font>
複製代碼
存檔後馬上生效
2 I& k; V/ S. z  c5 ]0 n  
5 t+ T+ R5 V2 w* k2 p+ j8 P" _Discuz 後台設定    後台->全局->SEO設置->URL靜態化8 `/ D' K, e& c

) S* j- O5 L# O4 L0 c: h  @
可以全選或依據網站需要勾選
! D& \+ z" K7 w
' P0 p; m" f) I' |0 z! ^




歡迎光臨 52AV手機A片王|52AV.ONE (https://www.52av.one/) Powered by Discuz! X3.2