pbootcms伪静态设置教程含apache、naginx、IIS不同环境配置规则

wdzsjl 2周前 (10-10) 阅读数 3 #易优eyoucms

其实pbootcms伪静态已经整理好, 在根目录就可以找到

作为使用者, 只需要根据不同的服务器环境, 使用不同格式的数据就行。 

naginx

#请复制下面伪静态配置到nginx配置文件中: #规则适合PbootCMS V2.0+版本  location / { 	if (!-e $request_filename){ 		rewrite ^/(.*)$ /index.php?p=$1 last; 	} }

apache

<IfModule mod_rewrite.c>   Options +FollowSymlinks   RewriteEngine On      RewriteCond %{REQUEST_FILENAME} !-d   RewriteCond %{REQUEST_FILENAME} !-f      RewriteRule ^(.*)$ index.php?p=$1 [QSA,PT,L]  </IfModule>

IIS

<?xml version="1.0" encoding="UTF-8"?> <configuration>     <system.webServer>         <rewrite>             <rules>                  <rule name="reIndex" stopProcessing="true">                     <match url="^(.*)$" ignoreCase="true" />                     <conditions logicalGrouping="MatchAll">                         <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />                         <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />                     </conditions>                     <action type="Rewrite" url="index.php?p={R:1}" appendQueryString="true" />                 </rule>             </rules>         </rewrite>     </system.webServer> </configuration>

如果自己不懂配置, 建议寻找技术支持。

wx.jpg ywfw.jpg
热门