apache mod_rewrite 問題 - Linux

Table of Contents


本人對Linux不是很熟 算是小小初學者

問題如果很蠢的話請見諒

我的問題是

我在某台主機的使用者目錄中建立的網站

http://123.123.123.123/~dylan/

使用mod_rewrite寫的.htaccess可以正常使用

也就是能正常將網址定義成我要的格式


但是當我想在

http://123.123.123.123/

這個根目錄下建立網站時

另外寫的.htaccess自訂網址卻無法正常使用

經測試之後

只要"不是"在 http://123.123.123.123/~XXXXXXX/ 這種使用者目錄下

.htaccess都是無效的

例如我如果如法炮製在 http://123.123.123.123/testtest/ 這個目錄下也放入

.htaccess用來自訂網址 也是沒辦法順利生效的


請問有板友遇過這種狀況嗎?

是我哪裡的設定沒開啟嗎?

我檢查過 httpd.conf

但是看不出所以然


註: 我是使用debian

/ect/apache2/ 內的檔案如下

dylan@cssa:/etc/apache2$ ls -a
. apache2.conf envvars mods-available ports.conf sites-enabled
.. conf.d httpd.conf mods-enabled sites-available


謝謝各位解惑

--

All Comments

Tristan Cohan avatarTristan Cohan2011-02-28
AllowOverride 要有開
Kristin avatarKristin2011-02-28
(worship)
Yedda avatarYedda2011-03-05
樓上 :o