2011-08-04 59 views
0

私はエイリアスに、このしようとしています:私のXAMPP/apacheの/ confに/エクストラ/ httpdの-xampp.confで/htdocs/test/index.phpXAMPP:エイリアスの問題 - エラー404

を、私は次のようしていますエントリ:

<IfModule alias_module> 
<IfModule mime_module> 
    Alias /test/ "D:/Installation/xampp/htdocs/test" 
    <Directory "D:/Installation/xampp/test"> 
      <IfModule php5_module> 
      <Files "index.php"> 
       php_admin_flag safe_mode off 
      </Files> 
     </IfModule> 
     Order allow,deny 
     Allow from all 
    </Directory> 
</IfModule> 
</IfModule> 

私がhttp://localhost/test/に行くと、ディレクトリ一覧が表示されます。このURLにhttp://localhost/test/と入力すると、このファイル/test/index.phpを開きたいと思います。

「localhost/test/index.php」というURLに直接アクセスしようとすると、「エラー404オブジェクトが見つかりません」というメッセージが表示されます。

私は間違っていますか?

# 
# DirectoryIndex: sets the file that Apache will serve if a directory 
# is requested. 
# 
<IfModule dir_module> 
    DirectoryIndex index.html index.htm 
</IfModule> 

のDirectoryIndexラインに "index.phpを" を追加します。

答えて

0

は、以下のあなたのhttpd-xampp.confファイルのセクションを検索します。

+0

あなたは上記のコードは、すでにhttpd.confファイルに含まれています。私はhttpd-xampp.confにそのコードを含めようとしましたが、その影響はありませんでした。あなたがお勧めできるものは何ですか? –

+0

私の悪い...それは今働いています。 –