有人能告诉我为什么我不能从子目录( subdir index.php )查看我的index.php吗?
它显示了http:// www.oorbellenboutique.nl/startpagina/index.php,但它必须是来自f:/inetpub/wwwroot/oorbellenboutique的index.php
正确的网址是:http:// www.oorbellenboutique.nl/index.php
我的DNS是:
A *.oorbellenboutique.nl → 83.87.163.224
A oorbellenboutique.nl → 83.87.163.224
CNAME www.oorbellenboutique.nl → oorbellenboutique.nl我的网址是:http://www.oorbellenboutique.nl
我在运行Apache2.x
NameVirtualHost 192.168.0.199:80
NameVirtualHost 192.168.0.199:443<VirtualHost 192.168.0.199:80 192.168.0.199:443>
ServerName oorbellenboutique.nl
ServerAlias www.oorbellenboutique.nl
DocumentRoot f:/inetpub/wwwroot/oorbellenboutique
RewriteEngine On
KeepAlive Off
DocumentRoot "f:/inetpub/wwwroot"
<Directory f:/inetpub/wwwroot/oorbellenboutique>
DirectoryIndex index.php
Order deny,allow
Allow from all
</Directory>
RewriteCond %{HTTP_HOST} ^(?:www\.)?oorbellenboutique\.nl$
ReWriteRule ^(.*) /oorbellenboutique/$1
</virtualhost>这是可行的,但网址现在是:
www.oorbellenboutique.nl/oorbellenboutique/index.php http://
如何使URL更短,比如:
www.oorbellenboutique.nl/index.php http://
NameVirtualHost 192.168.0.199:80
NameVirtualHost 192.168.0.199:443
< VirtualHost 192.168.0.199:80 192.168.0.199:443>
ServerName www.oorbellenboutique.nl
ServerAlias *.oorbellenboutique.nl oorbellenboutique.nl
选项+跟随符号链接
RewriteEngine打开
RewriteCond %{HTTP_HOST} ^(?:www.)?oorbellenboutique.nl$
<Directory f:/inetpub/wwwroot/oorbellenboutique>
DirectoryIndex index.html index.php
Order deny,allow
Allow from all
</Directory>RewriteRule ^/美元/欧奥本精品店/R
< /virtualhost>
发布于 2010-10-13 19:08:11
尝试在紧接RewriteBase指令之后添加一个RewriteEngine指令:
RewriteBase f:/inetpub/wwwroot这与DocumentRoot的功能不同--它是mod_rewrite所需要的。
https://stackoverflow.com/questions/3926224
复制相似问题