Home  >  Article  >  Backend Development  >  求高手看下这段伪静态规则错哪了

求高手看下这段伪静态规则错哪了

WBOY
WBOYOriginal
2016-06-13 12:49:20730browse

求高手看下这段伪静态规则哪里错了
Apache版本2.2.21,已开启伪静态功能

<br />
RewriteEngine On<br />
RewriteCond Host: (?!www.)([a-zA-Z0-9_-]+).abc.com<br />
RewriteRule ^(.*)/  /show.php\?domain=$1<br />


需求:类似于58同城的二级站,当用户访问 sdf.abc.com 时 自动调用show.php这个文件,同时将sdf这个值传入到这个文件中,show.php可以通过$_GET['domain']来获取sdf这个值,当访问haha.abc.com域名时自动将haha这个值传过去,泛解析和*.abc.com已绑定,但是现在的情况是访问任何二级域名都指向网站的根目录的默认文件(index.php),根本没调用show.php这个文件,也就是说伪静态没起作用


------解决方案--------------------
百度下看看 就是伪静态
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn