mediawiki 在网站根目录下的apache/openlitespeed伪静态规则
主机是cpanel ,服务器是openlitespeed
弄mediawiki 伪静态弄了好久,后来求助官方才弄好
注意,本次安装的mediawiki 程序是在网站根目录
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_URI} !^/(skins|images|mw-config|extensions)/
RewriteCond %{REQUEST_URI} !^/(redirect|texvc|index).php
# other notible conditions
RewriteCond %{REQUEST_URI} !^/error/(40(1|3|4)|500).html
RewriteCond %{REQUEST_URI} !^/favicon.ico
RewriteCond %{REQUEST_URI} !^/load.php
RewriteCond %{REQUEST_URI} !^/api.php
RewriteCond %{REQUEST_URI} !^/robots.txt
# Make sure there is no query string - unless user is making a search
RewriteCond %{QUERY_STRING} ^$ [OR] %{REQUEST_URI} ^/Special:Search
#I suspect that people who use /wiki will need the following line, but I'm not sure:
RewriteCond %{REQUEST_URI} ^/w$
#Rewrite URI/foo properly, this is the main rule.
RewriteRule ^(.*)$ /index.php/$1 [L,QSA,NE] # Quirk: Truncates question marks (%3F)
#RewriteRule ^(.*)http:/(.*) /$2 [R=301]
编辑LocalSettings.php文件添加下面代码
1
2
$wgScriptPath = "";
$wgArticlePath = "/$1";
💘 相关文章
- Openlitespeed wordpress伪静态出现404错误解决方法
- Openlitespeed /litespeed 常用的伪静态(rewrite)规则大全
- vanillaforums伪静态规则和memcached缓存的方法
- openLitespeed的教程
- 一款静态博客写作客户端-Gridea
- 基于OpenLiteSpeed免费的服务器,vps控制面板CyberPanel
- apache非www重定向到www和https的代码
- 在openlitespeed下配置acme.sh脚本证书折腾了两天
- Openlitespeed启用php74的详细方法
- openlitespeed/litespeed禁止访问文件夹和文件的方法