Discuz5.5在目录如何实现伪静态?
Discuz5.5放在Windwos服务器根目录下用httpd.ini实现伪静态.放在"域名/bbs/"这样的目录下如何实现伪静态.httpd.ini该如何修改....
Discuz5.5放在Windwos服务器根目录下用httpd.ini实现伪静态.
放在"域名/bbs/"这样的目录下如何实现伪静态.
httpd.ini该如何修改. 展开
放在"域名/bbs/"这样的目录下如何实现伪静态.
httpd.ini该如何修改. 展开
1个回答
展开全部
下载httpd.ini放到空间根目录,后台开启伪静态即可
前提是主机支持rewrite
[ISAPI_Rewrite]
# 3600 = 1 hour
CacheClockRate 3600
RepeatLimit 32
# Discuz! Rewrite规则
# 独立主机用户
# Protect httpd.ini and httpd.parse.errors files
# from accessing through HTTP
RewriteRule ^(.*)/archiver/((fid|tid)-[\w\-]+\.html)\?*(.*)$ $1/archiver/index\.php\?$2&$4
RewriteRule ^(.*)/forum-([0-9]+)-([0-9]+)\.html\?*(.*)$ $1/forumdisplay\.php\?fid=$2&page=$3&$4
RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html\?*(.*)$ $1/viewthread\.php\?tid=$2&extra=page\%3D$4&page=$3&$4
RewriteRule ^(.*)/space-(username|uid)-(.+)\.html\?*(.*)$ $1/space\.php\?$2=$3&$4
RewriteRule ^(.*)/tag-(.+)\.html\?*(.*)$ $1/tag\.php\?name=$2&$3
# SupeSite Rewrite规则
# 独立主机用户
# 修改以下语句中的 /supesite 修改为你的SupeSite目录地址,如果程序放在根目录中,请将 /supesite 修改为 /
RewriteRule ^/supesite/([0-9]+)$ /supesite/index\.php\?uid/$1 [L]
RewriteRule ^/supesite/([0-9]+)/spacelist(.+)$ /supesite/index\.php\?uid/$1/action/spacelist/type$2 [L]
RewriteRule ^/supesite/([0-9]+)/viewspace(.+)$ /supesite/index\.php\?uid/$1/action/viewspace/itemid$2 [L]
RewriteRule ^/supesite/([0-9]+)/viewbbs(.+)$ /supesite/index\.php\?uid/$1/action/viewbbs/tid$2 [L]
RewriteRule ^/supesite/([0-9]+)/(.*)$ /supesite/index\.php\?uid/$1/$2 [L]
RewriteRule ^/supesite/action(.+)$ /supesite/index\.php\?action$1 [L]
RewriteRule ^/supesite/category(.+)$ /supesite/index\.php\?action/category/catid$1 [L]
RewriteRule ^/supesite/viewnews(.+)$ /supesite/index\.php\?action/viewnews/itemid$1 [L]
RewriteRule ^/supesite/viewthread(.+)$ /supesite/index\.php\?action/viewthread/tid$1 [L]
RewriteRule ^/supesite/mygroup(.+)$ /supesite/index\.php\?action/mygroup/gid$1 [L]
# UCHome Rewrite规则
# 独立主机用户
# 修改以下语句中的 /uchome 修改为你的uchome目录地址,如果程序放在根目录中,请将 /uchome 修改为 /
RewriteRule ^/uchome/(space|network)-(.+)\.html$ /uchome/$1\.php\?rewrite=$2 [L]
RewriteRule ^/uchome/(space|network)\.html$ /uchome/$1\.php [L]
RewriteRule ^/uchome/([0-9]+)$ /uchome/space\.php\?uid=$1 [L]
# SupeV Rewrite规则
# 独立主机用户
RewriteRule ^(.*)/ivideo(-tv-([0-9]+))?(-ti-([0-9]+))?(-tc-([0-9]+))?(-page-([0-9]+))?\.html$ $1/ivideo\.php\?tv=$3&ti=$5&tc=$7&page=$9
RewriteRule ^(.*)/ispecial(-tv-([0-9]+))?(-ti-([0-9]+))?(-tc-([0-9]+))?(-page-([0-9]+))?\.html$ $1/ispecial\.php\?tv=$3&ti=$5&tc=$7&page=$9
RewriteRule ^(.*)/icategory\.html$ $1/icategory\.php
RewriteRule ^(.*)/category-cid-([0-9]+)(-tag-([^-]*))?(-timelimit-([0-9]+))?(-orderlimit-([0-9]+))?(-page-([0-9]+))?\.html$ $1/category\.php\?cid=$2&tag=$4&timelimit=$6&orderlimit=$8&page=$10
RewriteRule ^(.*)/vspace-(mid|username)-(.+)\.html$ $1/vspace\.php\?$2=$3
RewriteRule ^(.*)/video-(vid|ivid)-(.+)\.html$ $1/video\.php\?$2=$3
RewriteRule ^(.*)/special-spid-([0-9]+)\.html$ $1/special\.php\?spid=$2
前提是主机支持rewrite
[ISAPI_Rewrite]
# 3600 = 1 hour
CacheClockRate 3600
RepeatLimit 32
# Discuz! Rewrite规则
# 独立主机用户
# Protect httpd.ini and httpd.parse.errors files
# from accessing through HTTP
RewriteRule ^(.*)/archiver/((fid|tid)-[\w\-]+\.html)\?*(.*)$ $1/archiver/index\.php\?$2&$4
RewriteRule ^(.*)/forum-([0-9]+)-([0-9]+)\.html\?*(.*)$ $1/forumdisplay\.php\?fid=$2&page=$3&$4
RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html\?*(.*)$ $1/viewthread\.php\?tid=$2&extra=page\%3D$4&page=$3&$4
RewriteRule ^(.*)/space-(username|uid)-(.+)\.html\?*(.*)$ $1/space\.php\?$2=$3&$4
RewriteRule ^(.*)/tag-(.+)\.html\?*(.*)$ $1/tag\.php\?name=$2&$3
# SupeSite Rewrite规则
# 独立主机用户
# 修改以下语句中的 /supesite 修改为你的SupeSite目录地址,如果程序放在根目录中,请将 /supesite 修改为 /
RewriteRule ^/supesite/([0-9]+)$ /supesite/index\.php\?uid/$1 [L]
RewriteRule ^/supesite/([0-9]+)/spacelist(.+)$ /supesite/index\.php\?uid/$1/action/spacelist/type$2 [L]
RewriteRule ^/supesite/([0-9]+)/viewspace(.+)$ /supesite/index\.php\?uid/$1/action/viewspace/itemid$2 [L]
RewriteRule ^/supesite/([0-9]+)/viewbbs(.+)$ /supesite/index\.php\?uid/$1/action/viewbbs/tid$2 [L]
RewriteRule ^/supesite/([0-9]+)/(.*)$ /supesite/index\.php\?uid/$1/$2 [L]
RewriteRule ^/supesite/action(.+)$ /supesite/index\.php\?action$1 [L]
RewriteRule ^/supesite/category(.+)$ /supesite/index\.php\?action/category/catid$1 [L]
RewriteRule ^/supesite/viewnews(.+)$ /supesite/index\.php\?action/viewnews/itemid$1 [L]
RewriteRule ^/supesite/viewthread(.+)$ /supesite/index\.php\?action/viewthread/tid$1 [L]
RewriteRule ^/supesite/mygroup(.+)$ /supesite/index\.php\?action/mygroup/gid$1 [L]
# UCHome Rewrite规则
# 独立主机用户
# 修改以下语句中的 /uchome 修改为你的uchome目录地址,如果程序放在根目录中,请将 /uchome 修改为 /
RewriteRule ^/uchome/(space|network)-(.+)\.html$ /uchome/$1\.php\?rewrite=$2 [L]
RewriteRule ^/uchome/(space|network)\.html$ /uchome/$1\.php [L]
RewriteRule ^/uchome/([0-9]+)$ /uchome/space\.php\?uid=$1 [L]
# SupeV Rewrite规则
# 独立主机用户
RewriteRule ^(.*)/ivideo(-tv-([0-9]+))?(-ti-([0-9]+))?(-tc-([0-9]+))?(-page-([0-9]+))?\.html$ $1/ivideo\.php\?tv=$3&ti=$5&tc=$7&page=$9
RewriteRule ^(.*)/ispecial(-tv-([0-9]+))?(-ti-([0-9]+))?(-tc-([0-9]+))?(-page-([0-9]+))?\.html$ $1/ispecial\.php\?tv=$3&ti=$5&tc=$7&page=$9
RewriteRule ^(.*)/icategory\.html$ $1/icategory\.php
RewriteRule ^(.*)/category-cid-([0-9]+)(-tag-([^-]*))?(-timelimit-([0-9]+))?(-orderlimit-([0-9]+))?(-page-([0-9]+))?\.html$ $1/category\.php\?cid=$2&tag=$4&timelimit=$6&orderlimit=$8&page=$10
RewriteRule ^(.*)/vspace-(mid|username)-(.+)\.html$ $1/vspace\.php\?$2=$3
RewriteRule ^(.*)/video-(vid|ivid)-(.+)\.html$ $1/video\.php\?$2=$3
RewriteRule ^(.*)/special-spid-([0-9]+)\.html$ $1/special\.php\?spid=$2
Storm代理
2023-08-29 广告
2023-08-29 广告
"StormProxies是全球大数据IP资源服务商,其住宅代理网络由真实的家庭住宅IP组成,可为企业或个人提供满足各种场景的代理产品。点击免费测试(注册即送1G流量)StormProxies有哪些优势?1、IP+端口提取形式,不限带宽,I...
点击进入详情页
本回答由Storm代理提供
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询