0
我已經在我的AWS EC2 apache中設置了以下虛擬主機。apache url重寫不會從url中刪除IP地址
<VirtualHost 99.999.999.999:80>
DocumentRoot /var/www/html/mysite
ServerName site.com
# Other directives here ...
<FilesMatch "\.(ico|pdf|flv|jpg|jpeg|png|gif|js|css|swf)$">
Header set Cache-Control "max-age=290304000, public"
</FilesMatch>
</VirtualHost>
但是它仍然顯示URL作爲99.999.999.999/directory/index.php
我已經按照設置和我想知道如果有件事情我已經在這裏錯過了嗎?
我期待的結果是,當我在我的瀏覽器中鍵入www.site.com時,它會轉到www.site.com/directory/index.php。目前輸入這個將會發送給我99.999.999.999/directory/index.php。
我的印象是,設置在我定義將停止IP地址的方式,虛擬主機被顯示,而是顯示在服務器名稱爲site.com
什麼問題? – arco444
我假設你想要你的網址爲site.com/directory/index.php。 – CrazySabbath
你能多解釋一下嗎? – Rico