|
得到了sitestar的伪静态代码,做成httpd.ini文件,上传,没法用,我的虚拟空间是支持伪静态的。
问题终于解决了,是代码问题,我查了好久,终于知道伪静态的代码形式,作为我这个菜鸟真是不容易啊。
你们给的代码我直接写到了空文件httpd.ini中,然后上传,怎么实验也不好使,查了一圈才发现,代码的头应该加上[ISAPI_Rewrite],你们公布的代码中没有[ISAPI_Rewrite],我就直接存成文件了,唉,真是个菜鸟啊。
现在我终于知道了建站之星支持虚拟主机完整的规则文件httpd.ini的内容是什么了。如下:
[ISAPI_Rewrite]
RewriteRule ^/([a-zA-Z_]{1,})-([a-zA-Z_]{1,})\.html$ /index\.php\?_m=$1&_a=$2
RewriteRule ^/([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([0-9]{1,})\.html$ /index\.php\?_m=$1&_a=$2&$3=$4
RewriteRule ^/([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([0-9]{1,})-([a-zA-Z_]{1,})-([0-9]{1,})\.html$ /index\.php\?_m=$1&_a=$2&$3=$4&$5=$6
RewriteRule ^/([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([0-9]{1,})-([a-zA-Z_]{1,})-([0-9]{0,})-([a-zA-Z_]{1,})-([0-9]{0,})\.html$ /index\.php\?_m=$1&_a=$2&$3=$4&$5=$6&$7=$8
RewriteRule ^/admin/([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([0-9]{1,})-([a-zA-Z_]{1,})-([0-9]{0,})\.html$ /admin/index\.php\?_m=$1&_a=$2&$3=$4&$5=$6
RewriteRule ^/admin/([a-zA-Z_]{1,})-([a-zA-Z_]{1,})\.html$ /admin/index\.php\?_m=$1&_a=$2
RewriteRule ^/admin/([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([0-9]{1,})\.html$ /admin/index\.php\?_m=$1&_a=$2&$3=$4
RewriteRule ^/admin/([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([a-zA-Z_]{1,})-([0-9]{1,})-([a-zA-Z_]{1,})-([0-9]{1,})-([a-zA-Z_]{1,})-([0-9]{0,})\.html$ /admin/index\.php\?_m=$1&_a=$2&$3=$4&$5=$6&$7=$8
用记事本保存成httpd.ini文件,传到虚拟主机的程序目录就可以了,这一天真累,最后再鄙视一下我的空间商,不告诉我是怎么回事。 |
|