在一个服务器上装了SHOPEX 和DESTOON.
现在有冲突了。
怎么使各个站点的规则独立
下面的规则 导致aaa.com站点有问题!!!RewriteCond Host:(^(.*)\.aaa\.com$)
RewriteRule ^(.*)\.(aspx|asa|asax|dll|jsp|cgi|fcgi|pl)(.*)$ /404\.php
RewriteRule ^(.*)/file/(.*)\.php(.*)$ /404\.php
RewriteRule ^(.*)-htm-(.*)$ $1\.php\?$2
RewriteRule ^(.*)/show-([0-9]+)([\-])?([0-9]+)?\.html$ $1/show\.php\?itemid=$2&page=$4
RewriteRule ^(.*)/list-([0-9]+)([\-])?([0-9]+)?\.html$ $1/list\.php\?catid=$2&page=$4
RewriteRule ^(.*)/show/([0-9]+)/([0-9]+)?([/])?$ $1/show\.php\?itemid=$2&page=$3
RewriteRule ^(.*)/list/([0-9]+)/([0-9]+)?([/])?$ $1/list\.php\?catid=$2&page=$3
RewriteRule ^(.*)/([A-za-z0-9_\-]+)-c([0-9]+)-([0-9]+)\.html$ $1/list\.php\?catid=$3&page=$4
RewriteRule ^(.*)/com/([a-z0-9_\-]+)/([a-z]+)/(.*)\.html$ $1/index\.php\?homepage=$2&file=$3&rewrite=$4
RewriteRule ^(.*)/com/([a-z0-9_\-]+)/([a-z]+)([/])?$ $1/index\.php\?homepage=$2&file=$3
RewriteRule ^(.*)/com/([a-z0-9_\-]+)([/])?$ $1/index\.php\?homepage=$2
RewriteRule ^(.*)/([a-z]+)/(.*)\.shtml$ $1/$2/index\.php\?rewrite=$3# from accessing through HTTP
RewriteCond Host:(^www\.bbb\.com$)
RewriteRule ^(.*)/topic-(.+)\.html(\?(.*))*$ $1/portal\.php\?mod=topic&topic=$2&$4
RewriteRule ^(.*)/article-([0-9]+)-([0-9]+)\.html(\?(.*))*$ $1/portal\.php\?mod=view&aid=$2&page=$3&$5
RewriteRule ^(.*)/forum-(\w+)-([0-9]+)\.html(\?(.*))*$ $1/forum\.php\?mod=forumdisplay&fid=$2&page=$3&$5
RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html(\?(.*))*$ $1/forum\.php\?mod=viewthread&tid=$2&extra=page\%3D$4&page=$3&$6
RewriteRule ^(.*)/group-([0-9]+)-([0-9]+)\.html(\?(.*))*$ $1/forum\.php\?mod=group&fid=$2&page=$3&$5
RewriteRule ^(.*)/space-(username|uid)-(.+)\.html(\?(.*))*$ $1/home\.php\?mod=space&$2=$3&$5
RewriteRule ^(.*)/blog-([0-9]+)-([0-9]+)\.html(\?(.*))*$ $1/home\.php\?mod=space&uid=$2&do=blog&id=$3&$5
RewriteRule ^(.*)/(fid|tid)-([0-9]+)\.html(\?(.*))*$ $1/index\.php\?action=$2&value=$3&$5RewriteCond Host:(^www\.ccc\.com$)
RewriteRule ^/shopadmin/(.+).(html)$ /shopadmin/$1\.html [L]
RewriteRule ^/(.+).(html)$ /index\.php\?$1\.html [L]
RewriteRule ^/(.+).(xml)$ /index\.php\?$1\.xml [L]
RewriteRule ^/(utility|splash|sitemaps|search|product|paycenter|package|order|message|member|link|gift|common|page|tool|gallery|cart|passport|brand|news|art|comment|custom|action)(.*)$ /index.php\?$1$2 [L]

解决方案 »

  1.   

    RewriteCond Host:(^(.*)\.aaa\.com$)
    RewriteRule ^(.*)\.(aspx|asa|asax|dll|jsp|cgi|fcgi|pl)(.*)$ /404\.php
    RewriteRule ^(.*)/file/(.*)\.php(.*)$ /404\.php
    RewriteRule ^(.*)-htm-(.*)$ $1\.php\?$2
    RewriteRule ^(.*)/show-([0-9]+)([\-])?([0-9]+)?\.html$ $1/show\.php\?itemid=$2&page=$4
    RewriteRule ^(.*)/list-([0-9]+)([\-])?([0-9]+)?\.html$ $1/list\.php\?catid=$2&page=$4
    RewriteRule ^(.*)/show/([0-9]+)/([0-9]+)?([/])?$ $1/show\.php\?itemid=$2&page=$3
    RewriteRule ^(.*)/list/([0-9]+)/([0-9]+)?([/])?$ $1/list\.php\?catid=$2&page=$3
    RewriteRule ^(.*)/([A-za-z0-9_\-]+)-c([0-9]+)-([0-9]+)\.html$ $1/list\.php\?catid=$3&page=$4
    RewriteRule ^(.*)/com/([a-z0-9_\-]+)/([a-z]+)/(.*)\.html$ $1/index\.php\?homepage=$2&file=$3&rewrite=$4
    RewriteRule ^(.*)/com/([a-z0-9_\-]+)/([a-z]+)([/])?$ $1/index\.php\?homepage=$2&file=$3
    RewriteRule ^(.*)/com/([a-z0-9_\-]+)([/])?$ $1/index\.php\?homepage=$2
    RewriteRule ^(.*)/([a-z]+)/(.*)\.shtml$ $1/$2/index\.php\?rewrite=$3 [L]
      

  2.   


    在没加CCC.COM规则前,aaa.com正常的。
    加了最后的CCC.COM规则后,AAA.COM出现问题了
      

  3.   

    为什么都写在一起??haccess里面不是更好。