欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

dedecms偽靜態(tài)設(shè)置以及目錄鏈接301跳轉(zhuǎn)實(shí)現(xiàn)方法(偽靜態(tài))

  發(fā)布時(shí)間:2017-09-16 11:12:31   作者:佚名   我要評(píng)論
本篇文章主要新增了適用于dedecms的個(gè)性化偽靜態(tài)文章鏈接設(shè)置,以及網(wǎng)站的目錄鏈接301跳轉(zhuǎn)和文章鏈接301跳轉(zhuǎn)規(guī)則!各位有不懂的可以留言,我盡最大努力幫助大家

htaccess偽靜態(tài)的規(guī)則

通過(guò)htaccess使用偽靜態(tài),則必須空間商支持Rewrite模塊,該模塊負(fù)責(zé)URL的重寫。否則即便是設(shè)置好了,也無(wú)法使用,并且還有可能出現(xiàn)500錯(cuò)誤。

下面是dedecms的偽靜態(tài)設(shè)置文本(部分參考):

個(gè)性化偽靜態(tài)還需要配合修改dedecms后臺(tái)文件才能實(shí)現(xiàn)

效果為www.***.com/plus/view.php?aid=123轉(zhuǎn)化為www.***.com/html/123/123.html

具體規(guī)則大家可以根據(jù)自己的需要進(jìn)行修改!

RewriteEngine On  
RewriteRule ^category/list-([0-9]+)\.html$ /plus/list.php?tid=$1  
RewriteRule ^category/list-([0-9]+)-([0-9]+)-([0-9]+)\.html$ /plus/list.php?tid=$1&totalresult=$2&PageNo=$3  
RewriteRule ^archives/view-([0-9]+)-([0-9]+)\.html$ /plus/view.php?arcID=$1&pageno=$2  
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  //個(gè)性化偽靜態(tài)文章鏈接  
RewriteRule ^list_([0-9]+)-([0-9]+)-([0-9]+).html$ list.php?tid=$1&TotalResult=$2&PageNo=$3  
RewriteRule ^html/([0-9]+)([0-9]+)/([0-9]+).html$ /plus/view.php?aid=$3

5.目錄和文章鏈接的301跳轉(zhuǎn)

該功能可以實(shí)現(xiàn)網(wǎng)站目錄鏈接和文章鏈接的301跳轉(zhuǎn)

RewriteEngine On  
RewriteBase /  
RewriteRule ^html/it/(.+)$ https://www.***.com/html/$1 [R=301,L]

效果是:訪問(wèn)www.***.com/html/it/*.html 會(huì)跳轉(zhuǎn)到www.***.com/html/.html 這個(gè)上面

相關(guān)文章

最新評(píng)論