环境: php5.5左右吧+mysql
先导入数据库文件db/db.sql
再修改config.php数据库配置
然后服务器设置好伪静态规则
访问网站OK
Nginx伪静态规则
rewrite ^/index.html$ /index.php;
rewrite ^/about.html$ /about.php;
rewrite ^/search.html$ /search.php;
rewrite ^/apply.html$ /apply.php;
rewrite ^/404.html$ /404.php;
rewrite ^/sort([1-9]+[0-9]*).html$ /sort.php?id=$1;
rewrite ^/sort([a-zA-Z]+).html$ /sort.php?alias=$1;
rewrite ^/site-([1-9]+[0-9]*).html$ /site.php?id=$1;
Apache的伪静态规则
RewriteEngine On
rewritebase /
RewriteRule ^index.\html /index\.php [L,NC]
RewriteRule ^about\.html about\.php [L,NC]
RewriteRule ^search\.html search\.php [L,NC]
RewriteRule ^apply\.html apply\.php [L,NC]
RewriteRule ^404\.html 404\.php [L,NC]
RewriteRule ^sort([0-9]+)\.html sort\.php?id=$1 [L,NC]
RewriteRule ^sort([a-zA-Z]+)\.html sort\.php?alias=$1 [L,NC]
RewriteRule ^site-([0-9]+)\.html site\.php?id=$1 [L,NC]
本站声明 ①. 本站赞助VIP,仅需【88】元即可 ! ! ! (赞助后享受整站资源全部免费下载) ②. 分享目的仅供大家学习和交流,请不要用于商业用途及非法用途,否则后果自负! ③. 如果你也有好源码或者教程,可以到投稿区发布,分享有金币奖励和额外收入! ④. 本站提供的源码、模板、插件等等其他资源,都不包含技术服务请大家谅解! ⑤. 如有链接无法下载、失效或广告,请联系管理员处理! ⑥. 本站资源售价只是赞助,收取费用仅维持本站的日常运营所需! ⑦.在您的能力范围内,为了大环境的良性发展,请尽可能的选择正版资源。 ⑧. 网站资源不做任何二次加密和授权后门(原版加密除外) 原文链接:http://www.duocaizy.com/7125.html,转载请注明出处。
评论0