请教下关于5.9SE版本多城市的apache伪静态规则怎么部署吗?

lxhandlxh

lxhandlxh

发表于 2019-11-13 11:06:08

apache 宝塔搭建的项目,多城市的伪静态能否举例说明一下规则如何修改,比如北京这个城市的伪静态规则应该是什么?目前是用的圈子里面下载的伪静态规则,但是针对多城市版本的无效,不知道如何修改。能否修改一个城市 如何配置 然后其他城市我们自己对着修改就可以。

相信使用蚂蚁的很多用户都不知道多城市版的应该怎么去修改。

用户评论(1)
  • gj368

    gj368 2021-08-15 20:04:36

    RewriteEngine On

    RewriteBase /

    #PC端


    RewriteRule ([a-zA-Z]+)/$ $1/index.php

    RewriteRule ([a-zA-Z]+)/category-catid-([0-9]+).html$ $1/category.php?catid=$2

    RewriteRule ([a-zA-Z]+)/category-catid-([0-9]+)-page-([0-9]+).html$ $1/category.php?catid=$2&page=$3

    RewriteRule ([a-zA-Z]+)/category-catid-([0-9]+)-areaid-([0-9]+).html$ $1/category.php?catid=$2&areaid=$3

    RewriteRule ([a-zA-Z]+)/category-catid-([0-9]+)-areaid-([0-9]+)-page-([0-9]+).html$ $1/category.php?catid=$2&areaid=$3&page=$4

    RewriteRule ([a-zA-Z]+)/category-catid-([0-9]+)-areaid-([0-9]+)-([a-zA-Z]+)-([0-9]+).html$ $1/category.php?catid=$2&areaid=$3&$4=$5

    RewriteRule ([a-zA-Z]+)/category-catid-([0-9]+)-([a-zA-Z_]+)-([0-9~]+).html$ $1/category.php?catid=$2&$3=$4

    RewriteRule ([a-zA-Z]+)/category-catid-([0-9]+)-([a-zA-Z_]+)-([0-9~]+)-([a-zA-Z_]+)-([0-9~]+).html$ $1/WWW.XXX.COM?catid=$2&$3=$4&$5=$6





    RewriteRule ([a-zA-Z]+)/space/(.+)/$ $1/space.php?user=$2

    RewriteRule ([a-zA-Z]+)/store-([0-9]+)/$ $1/store.php?uid=$2

    RewriteRule ([a-zA-Z]+)/store-([0-9]+)/([\/]+).html$ $1/store.php?uid=$2&Uid=$3

    RewriteRule ([a-zA-Z]+)/(?!store|space)(.+)/$ $1/category.php?Catid=$2

    RewriteRule ([a-zA-Z]+)/information-id-([0-9]+).html$ $1/information.php?id=$2




    RewriteRule ([a-zA-Z]+)/news.html$ $1/news.php

    RewriteRule ([a-zA-Z]+)/news-id-([0-9]+).html$ $1/news.php?id=$2

    RewriteRule ([a-zA-Z]+)/news-catid-([0-9]+).html$ $1/news.php?catid=$2

    RewriteRule ([a-zA-Z]+)/news-catid-([0-9]+)-page-([0-9]+).html$ $1/news.php?catid=$2&page=$3




    RewriteRule ([a-zA-Z]+)/goods.html$ $1/goods.php

    RewriteRule ([a-zA-Z]+)/goods-id-([0-9]+).html$ $1/goods.php?id=$2

    RewriteRule ([a-zA-Z]+)/goods-([\/]+).html$ $1/goods.php?Catid=$2

    RewriteRule ([a-zA-Z]+)/coupon.html$ $1/coupon.php

    RewriteRule ([a-zA-Z]+)/coupon-id-([0-9]+).html$ $1/coupon.php?id=$2

    RewriteRule ([a-zA-Z]+)/coupon-([\/]+).html$ $1/coupon.php?Catid=$2

    RewriteRule ([a-zA-Z]+)/group.html$ $1/group.php

    RewriteRule ([a-zA-Z]+)/group-id-([0-9]+).html$ $1/group.php?id=$2

    RewriteRule ([a-zA-Z]+)/group-([\/]+).html$ $1/group.php?Catid=$2

    RewriteRule ([a-zA-Z]+)/corporation.html$ $1/corporation.php

    RewriteRule ([a-zA-Z]+)/corporation-([a-zA-Z_]+)-([0-9~]+).html$ $1/corporation.php?$2=$3

    RewriteRule ([a-zA-Z]+)/corporation-([a-zA-Z_]+)-([0-9~]+)-([a-zA-Z_]+)-([0-9~]+).html$ $1/corporation.php?$2=$3&$4=$5

    RewriteRule ([a-zA-Z]+)/corporation-([a-zA-Z_]+)-([0-9~]+)-([a-zA-Z_]+)-([0-9~]+)-([a-zA-Z_]+)-([0-9~]+).html$ $1/corporation.php?$2=$3&$4=$5&$6=$7

    RewriteRule ([a-zA-Z]+)/corporation-([\/]+).html$ $1/corporation.php?Catid=$2

    RewriteRule ([a-zA-Z]+)/aboutus.html$ $1/about.php?part=aboutus

    RewriteRule ([a-zA-Z]+)/sitemap.html$ $1/about.php?part=sitemap

    RewriteRule ([a-zA-Z]+)/aboutus-id-([0-9]+).html$ $1/about.php?part=aboutus&id=$2

    RewriteRule ([a-zA-Z]+)/announce.html$ $1/about.php?part=announce&id=$2

    RewriteRule ([a-zA-Z]+)/faq.html$ $1/about.php?part=faq

    RewriteRule ([a-zA-Z]+)/faq-id-([0-9]+).html$ $1/about.php?part=faq&id=$2

    RewriteRule ([a-zA-Z]+)/friendlink.html$ $1/about.php?part=friendlink


    RewriteRule index.html$ index.php

    RewriteRule category-catid-([0-9]+).html$ category.php?catid=$1

    RewriteRule category-catid-([0-9]+)-page-([0-9]+).html$ category.php?catid=$1&page=$2

    RewriteRule category-catid-([0-9]+)-areaid-([0-9]+).html$ category.php?catid=$1&areaid=$2

    RewriteRule category-catid-([0-9]+)-areaid-([0-9]+)-page-([0-9]+).html$ category.php?catid=$1&areaid=$2&page=$3

    RewriteRule category-catid-([0-9]+)-areaid-([0-9]+)-([a-zA-Z]+)-([0-9]+).html$ category.php?catid=$1&areaid=$2&$3=$4

    RewriteRule category-catid-([0-9]+)-([a-zA-Z_]+)-([0-9~]+).html$ category.php?catid=$1&$2=$3

    RewriteRule category-catid-([0-9]+)-([a-zA-Z_]+)-([0-9~]+)-([a-zA-Z_]+)-([0-9~]+).html$ category.php?catid=$1&$2=$3&$4=$5

    RewriteRule space/(.+)/$ space.php?user=$1


    RewriteRule store-([0-9]+)/$ store.php?uid=$1

    RewriteRule store-([0-9]+)/1.html$ store.php?uid=$1

    RewriteRule store-([0-9]+)/info.html$ store.php?uid=$1&part=info

    RewriteRule store-([0-9]+)/about.html$ store.php?uid=$1&part=about

    RewriteRule store-([0-9]+)/document-typeid-([0-9]+).html$ store.php?uid=$1&part=document&typeid=$2

    RewriteRule store-([0-9]+)/comment.html$ store.php?uid=$1&part=comment

    RewriteRule store-([0-9]+)/album.html$ store.php?uid=$1&part=album

    RewriteRule store-([0-9]+)/contactus.html$ store.php?uid=$1&part=contactus

    RewriteRule store-([0-9]+)/goods.html$ store.php?uid=$1&part=goods



    RewriteRule store-([0-9]+)/([\/]+).html$ store.php?uid=$1&Uid=$2

    RewriteRule (?!store|space)(.+)/$ category.php?Catid=$1

    RewriteRule ([0-9]+).html$ information.php?id=$1

    RewriteRule ([a-zA-Z]+)/([0-9]+).html$ $1/information.php?id=$2

    RewriteRule news.html$ news.php

    RewriteRule news-id-([0-9]+).html$ news.php?id=$1

    RewriteRule news-catid-([0-9]+).html$ news.php?catid=$1

    RewriteRule news-catid-([0-9]+)-page-([0-9]+).html$ news.php?catid=$1&page=$2

    #RewriteRule goods.html$ goods.php

    RewriteRule goods-id-([0-9]+).html$ goods.php?id=$1

    RewriteRule goods-([\/]+).html$ goods.php?Catid=$1

    RewriteRule coupon.html$ coupon.php

    RewriteRule coupon-id-([0-9]+).html$ coupon.php?id=$1

    RewriteRule coupon-([\/]+).html$ coupon.php?Catid=$1

    RewriteRule group.html$ group.php

    RewriteRule group-id-([0-9]+).html$ group.php?id=$1

    RewriteRule group-([\/]+).html$ group.php?Catid=$1

    RewriteRule corporation.html$ corporation.php

    RewriteRule corporation-([a-zA-Z_]+)-([0-9~]+).html$ corporation.php?$1=$2

    RewriteRule corporation-([a-zA-Z_]+)-([0-9~]+)-([a-zA-Z_]+)-([0-9~]+).html$ corporation.php?$1=$2&$3=$4

    RewriteRule corporation-([a-zA-Z_]+)-([0-9~]+)-([a-zA-Z_]+)-([0-9~]+)-([a-zA-Z_]+)-([0-9~]+).html$ corporation.php?$1=$2&$3=$4&$5=$6

    RewriteRule corporation-([\/]+).html$ corporation.php?Catid=$1

    RewriteRule aboutus.html$ about.php?part=aboutus

    RewriteRule sitemap.html$ about.php?part=sitemap

    RewriteRule aboutus-id-([0-9]+).html$ about.php?part=aboutus&id=$1

    RewriteRule announce.html$ about.php?part=announce&id=$1

    RewriteRule faq.html$ about.php?part=faq

    RewriteRule faq-id-([0-9]+).html$ about.php?part=faq&id=$1

    RewriteRule friendlink.html$ about.php?part=friendlink


    # php -- BEGIN cPanel-generated handler, do not edit

    # Set the “ea-php54” package as the default “PHP” programming language.

    <IfModule mime_module>

      AddHandler application/x-httpd-ea-php54 .php .php5 .phtml

    </IfModule>

    # php -- END cPanel-generated handler, do not edit


    # BEGIN cPanel-generated php ini directives, do not edit

    # Manual editing of this file may result in unexpected behavior.

    # To make changes to this file, use the cPanel MultiPHP INI Editor (Home >> Software >> MultiPHP INI Editor)

    # For more information, read our documentation (https://go.cpanel.net/EA4ModifyINI)

    <IfModule php5_module>

       php_flag asp_tags Off

       php_flag display_errors Off

       php_value max_execution_time 30

       php_value max_input_time 60

       php_value max_input_vars 1000

       php_value memory_limit 256M

       php_value post_max_size 516M

       php_value session.gc_maxlifetime 1440

       php_value session.save_path "/var/cpanel/php/sessions/ea-php54"

       php_value upload_max_filesize 512M

       php_flag zlib.output_compression On

    </IfModule>

    <IfModule lsapi_module>

       php_flag asp_tags Off

       php_flag display_errors Off

       php_value max_execution_time 30

       php_value max_input_time 60

       php_value max_input_vars 1000

       php_value memory_limit 256M

       php_value post_max_size 516M

       php_value session.gc_maxlifetime 1440

       php_value session.save_path "/var/cpanel/php/sessions/ea-php54"

       php_value upload_max_filesize 512M

       php_flag zlib.output_compression On

    </IfModule>

    # END cPanel-generated php ini directives, do not edit