永久黄网站色视频免费直播,yy6080三理论日本中文,亚洲无码免费在线观看视频,欧美日韩精品一区二区在线播放

Board logo

標(biāo)題: [分享] linux下主流網(wǎng)站的偽靜態(tài)規(guī)則 想要就進(jìn)來(lái)拿吧!! [打印本頁(yè)]

作者: marquis    時(shí)間: 2012-7-20 14:56     標(biāo)題: linux下主流網(wǎng)站的偽靜態(tài)規(guī)則 想要就進(jìn)來(lái)拿吧!

本帖最后由 marquis 于 2012-7-25 11:42 編輯

這里收集的都是主流網(wǎng)站源碼包的偽靜態(tài)規(guī)則
wdcp已經(jīng)默認(rèn)添加了dzx15,dzx7的nginx和apache偽靜態(tài)規(guī)則了
在nginx下的偽靜態(tài)規(guī)則
   wordpress
  location / {
        index index.html index.php;
        if (-f $request_filename/index.html){
            rewrite (.*) $1/index.html break;
        }
        if (-f $request_filename/index.php){
            rewrite (.*) $1/index.php;
        }
        if (!-f $request_filename){
            rewrite (.*) /index.php;
        }
    }


  shopex
location / {
if (!-e $request_filename) {
rewrite ^/(.+.(html|xml|json|htm|php|jsp|asp|shtml))$ /index.php?$1 last;
         }
}




  phpcms
location / {
###以下為PHPCMS 偽靜態(tài)化rewrite規(guī)則
rewrite ^(.*)show-([0-9]+)-([0-9]+).html$ $1/show.php?itemid=$2&page=$3;
rewrite ^(.*)list-([0-9]+)-([0-9]+).html$ $1/list.php?catid=$2&page=$3;
rewrite ^(.*)show-([0-9]+).html$ $1/show.php?specialid=$2;

####以下為PHPWind 偽靜態(tài)化rewrite規(guī)則
rewrite ^(.*)-htm-(.*)$ $1.php?$2 last;
rewrite ^(.*)/simple/([a-z0-9_]+.html)$ $1/simple/index.php?$2 last;
}


  emlog4.0
location / {
        index index.php index.html;
        if (!-e $request_filename)
        {
                rewrite ^/(.+)$ /index.php last;
        }
}





  phpwind
location / {
rewrite ^(.*)-htm-(.*)$ $1.php?$2 last;
rewrite ^(.*)/simple/([a-z0-9\_]+\.html)$ $1/simple/index.php?$2 last;
}




  SaBlog2.0
# 只帶月份的歸檔
rewrite "^/date/([0-9]{6})/?([0-9]+)?/?$" /index.php?action=article&setdate=$1&page=$2 last;
# 無(wú)分類(lèi)翻頁(yè)
rewrite ^/page/([0-9]+)?/?$ /index.php?action=article&page=$1 last;
# 分類(lèi)
rewrite ^/category/([0-9]+)/?([0-9]+)?/?$ /index.php?action=article&cid=$1&page=$2 last;
rewrite ^/category/([^/]+)/?([0-9]+)?/?$ /index.php?action=article&curl=$1&page=$2 last;
# 歸檔、高級(jí)搜索
rewrite ^/(archives|search|article|links)/?$ /index.php?action=$1 last;
# 全部評(píng)論、標(biāo)簽列表、引用列表 帶分頁(yè)
rewrite ^/(comments|tagslist|trackbacks|article)/?([0-9]+)?/?$ /index.php?action=$1&page=$2 last;
# tags
rewrite ^/tag/([^/]+)/?([0-9]+)?/?$ /index.php?action=article&item=$1&page=$2 last;
# 文章
rewrite ^/archives/([0-9]+)/?([0-9]+)?/?$ /index.php?action=show&id=$1&page=$2 last;
# RSS rewrite ^/rss/([0-9]+)?/?$ /rss.php?cid=$1 last;
rewrite ^/rss/([^/]+)/?$ /rss.php?url=$1 last;
# 用戶(hù) rewrite ^/uid/([0-9]+)/?([0-9]+)?/?$ /index.php?action=article&uid=$1&page=$2 last;
rewrite ^/user/([^/]+)/?([0-9]+)?/?$ /index.php?action=article&user=$1&page=$2 last;
# 地圖文件
rewrite sitemap.xml sitemap.php last;
# 自定義鏈接
rewrite ^(.*)/([0-9a-zA-Z\-\_]+)/?([0-9]+)?/?$ $1/index.php?action=show&alias=$2&page=$3 last;


  Typecho
location / {
        index index.html index.php;
        if (-f $request_filename/index.html){
            rewrite (.*) $1/index.html break;
        }
        if (-f $request_filename/index.php){
            rewrite (.*) $1/index.php;
        }
        if (!-f $request_filename){
            rewrite (.*) /index.php;
        }
    }








在apache下的偽靜態(tài)規(guī)則

  DEDE
<IfModule mod_rewrite.c>
       RewriteEngine On
RewriteRule ^plus/list-([0-9]+)\.html$ /plus/list.php?tid=$1
RewriteRule ^plus/list-([0-9]+)-([0-9]+)-([0-9]+)\.html$ /plus/list.php?tid=$1&totalresult=$2&PageNo=$3
RewriteRule ^plus/view-([0-9]+)-1\.html$ /plus/view.php?arcID=$1
RewriteRule ^plus/view-([0-9]+)-([0-9]+)\.html$ /plus/view.php?aid=$1&pageno=$2



</IfModule>


  dzx2.5
<IfModule mod_rewrite.c>
       ewriteEngine On
       RewriteBase /

# Rewrite 系統(tǒng)規(guī)則請(qǐng)勿修改

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^topic-(.+)\.html$ portal.php?mod=topic&topic=$1&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^article-([0-9]+)-([0-9]+)\.html$ portal.php?mod=view&aid=$1&page=$2&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^forum-(\w+)-([0-9]+)\.html$ forum.php?mod=forumdisplay&fid=$1&page=$2&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^thread-([0-9]+)-([0-9]+)-([0-9]+)\.html$ forum.php?mod=viewthread&tid=$1&extra=page\%3D$3&page=$2&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^group-([0-9]+)-([0-9]+)\.html$ forum.php?mod=group&fid=$1&page=$2&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^space-(username|uid)-(.+)\.html$ home.php?mod=space&$1=$2&%1

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^([a-z]+)-(.+)\.html$ $1.php?rewrite=$2&%1

</IfModule>



  phpwind
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule ^(.*)/thread-htm-tid-(\d+)-(.*).html  $1/thread.php?fid=$2
RewriteRule ^(.*)/read-htm-tid-(\d+)-(.*).html  $1/read.php?tid=$2
RewriteRule ^(.*)/commtopics-(\d+)-(.*)$ $1/thread.php?fid=$2&page=$3
RewriteRule ^(.*)/commtopics-(.*)$      $1/thread.php?fid=$2&page=$3
RewriteRule ^(.*)/article-(\d+)-(\d+)-(.*).html$  $1/read.php?tid=$2&page=$3&fpage=$4
RewriteRule ^(.*)/article-(\d+)-(.*).html$       $1/read.php?tid=$2&page=$3
RewriteRule ^(.*)/article-(.*).html$         $1/read.php?tid=$2
RewriteRule ^(.*)-htm-(.*)$ $1.php?$2
RewriteRule ^(.*)/simple/([a-z0-9\_]+\.html)$ $1/simple/index.php?$2
</IfModule>



  wordpress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>



  持續(xù)更新中 。。。。。(更新放在樓下)
作者: huzs1622    時(shí)間: 2012-7-20 15:33

支持樓主的分享精神!
作者: 藤真    時(shí)間: 2012-7-20 15:59

收藏了,支持樓主。
作者: marquis    時(shí)間: 2012-7-20 17:08

zencart的apache偽靜態(tài)規(guī)則
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
# From Ultimate SEO URLs
RewriteRule ^(.*)-p-(.*).html$ index\.php?main_page=product_info&amp;products_id=$2&amp;%{QUERY_STRING} [L]RewriteRule ^(.*)-c-(.*).html$ index\.php?main_page=index&amp;cPath=$2&amp;%{QUERY_STRING} [L]
RewriteRule ^(.*)-m-([0-9]+).html$ index\.php?main_page=index&amp;manufacturers_id=$2&amp;%{QUERY_STRING} [L]
RewriteRule ^(.*)-pi-([0-9]+).html$ index\.php?main_page=popup_image&amp;pID=$2&amp;%{QUERY_STRING} [L]RewriteRule ^(.*)-pr-([0-9]+).html$ index\.php?main_page=product_reviews&amp;products_id=$2&amp;%{QUERY_STRING} [L]
RewriteRule ^(.*)-pri-([0-9]+).html$ index\.php?main_page=product_reviews_info&amp;products_id=$2&amp;%{QUERY_STRING} [L]
# For Open Operations Info Manager<br />RewriteRule ^(.*)-i-([0-9]+).html$ index\.php?main_page=info_manager&amp;pages_id=$2&amp;%{QUERY_STRING} [L]
# For dreamscape's News &amp; Articles Manager
RewriteRule ^news$ index\.php?main_page=news&amp;%{QUERY_STRING} [L]
RewriteRule ^news/rss.xml$ index\.php?main_page=news_rss&amp;%{QUERY_STRING} [L]
RewriteRule ^news/archive$ index\.php?main_page=news_archive&amp;%{QUERY_STRING} [L]
RewriteRule ^news/([0-9]{4})-([0-9]{2})-([0-9]{2}).html$ index\.php?main_page=news&amp;date=$1-$2-$3&amp;%{QUERY_STRING} [L]
RewriteRule ^news/archive/([0-9]{4})-([0-9]{2}).html$ index\.php?main_page=news_archive&amp;date=$1-$2&amp;%{QUERY_STRING} [L]
RewriteRule ^news/(.*)-a-([0-9]+)-comments.html$ index\.php?main_page=news_comments&amp;article_id=$2&amp;%{QUERY_STRING} [L]
RewriteRule ^news/(.*)-a-([0-9]+).html$ index\.php?main_page=news_article&amp;article_id=$2&amp;%{QUERY_STRING} [L]
RewriteRule ^-ezp-(.*).html$ index\.php?main_page=page&amp;id=$1&amp;%{QUERY_STRING} [L]
# All other pages
# Don't rewrite real files or directories
RewriteCond %{REQUEST_FILENAME} !-f [NC]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*).html$ index\.php?main_page=$1&amp;%{QUERY_STRING} [L]
</IfModule>
作者: qq682907    時(shí)間: 2012-10-14 13:25

怎么沒(méi)有nginx? 我要DZ2.5的 完整版的。
作者: happyxinqiang    時(shí)間: 2012-11-16 16:26

Joomla的,急需啊~
作者: upchum    時(shí)間: 2013-1-31 14:04

這個(gè)wordpress是有一個(gè)問(wèn)題的:wp-admin后臺(tái)也會(huì)靜態(tài)化,就會(huì)出現(xiàn)問(wèn)題
作者: 3g210    時(shí)間: 2013-3-19 09:05

回復(fù) 1# marquis

我是nginx+apache 表示nginx+apache+php+mysql的組合的,是用nginx或者apache哪個(gè)偽靜態(tài)規(guī)則呢
作者: marquis    時(shí)間: 2013-3-19 10:34

apache。。。。




歡迎光臨 WDlinux官方論壇 (http://www.fsowen.com/bbs/) Powered by Discuz! 7.2