平潭便民网,这个网站用的是蚂蚁分类信息这套程序,单年买了单城市+多城市版本。这些年域名一直续费,服务器也一直续费,就这样放着。半死不活的,我这个不合格的站长。。。
服务器环境:Nginx1.12+PHP5.3+Mysql5.6+zend3.3,设置比较简单,后台开启伪静态就可以了。官方不提供nginx版伪静态,能找到的都是Apache转nginx的工具,直接转换官方的规则使用还是不合适,以下是平潭便民网正在使用5.9单城市版本的伪静态规则
rewrite ^/space/(.+)/$ /space.php?user=$1;
rewrite ^/store-([0-9]+)/$ /store.php?uid=$1;
rewrite ^/store-([0-9]+)/([^/]+).html$ /store.php?uid=$1&Uid=$2;
if (!-d $request_filename){
set $rule_3 1$rule_3;
}
if ($rule_3 = "1"){
rewrite ^/(?!store|space)(.+)/$ /category.php?Catid=$1;
}
rewrite ^/([^/]+)/([0-9]+).html$ /information.php?id=$2;
rewrite ^/news.html$ /news.php;
rewrite ^/news-id-([0-9]+).html$ /news.php?id=$1;
rewrite ^/news-catid-([0-9]+).html$ /news.php?catid=$1;
rewrite ^/news-catid-([0-9]+)-page-([0-9]+).html$ /news.php?catid=$1&page=$2;
rewrite ^/goods.html$ /goods.php;
rewrite ^/goods-id-([0-9]+).html$ /goods.php?id=$1;
rewrite ^/goods-([^/]+).html$ /goods.php?Catid=$1;
rewrite ^/corporation.html$ /corporation.php;
rewrite ^/corporation-([^/]+).html$ /corporation.php?Catid=$1;
rewrite ^/aboutus.html$ /about.php?part=aboutus;
rewrite ^/sitemap.html$ /about.php?part=sitemap;
rewrite ^/aboutus-id-([0-9]+).html$ /about.php?part=aboutus&id=$1;
rewrite ^/announce.html$ /about.php?part=announce&id=$1;
rewrite ^/faq.html$ /about.php?part=faq;
rewrite ^/faq-id-([0-9]+).html$ /about.php?part=faq&id=$1;
rewrite ^/friendlink.html$ /about.php?part=friendlink;
rewrite ^/vip.html$ /vip.php;
宝塔面板的话直接到后台添加伪静态规则即可
毛桃博客







评论前必须登录!
注册