ユーザ用ツール

サイト用ツール


apache:virtualhosts

差分

このページの2つのバージョン間の差分を表示します。

この比較画面へのリンク

次のリビジョン
前のリビジョン
apache:virtualhosts [2011/05/27 08:06] – 外部編集 127.0.0.1apache:virtualhosts [2025/02/16 13:53] (現在) – 外部編集 127.0.0.1
行 1: 行 1:
-====== Contents  ====== +====== virtualhosts  ======
- +
-====== 構築  ======+
  
 ===== httpd.conf  ===== ===== httpd.conf  =====
行 54: 行 52:
 </code> </code>
  
 +===== Tips =====
 +
 +==== .htaccessが無視される ====
 +.htaccessはディレクトリ毎に設定されるので、デフォルトのDocumentRoot以外をVitrualHostに設定すると、その配下では.htaccessは無視される。
 +VirtualHostディレクティブにDirectoryディレクティブを定義して、「AllowOverride All」を定義すれば良い。
 +
 +<code>
 +<VirtualHost *:80>
 +  ServerName vhost.co.jp
 +  DocumentRoot /var/www_vhost/html
 +  <Directory /var/www_vhost/html>
 +    AllowOverride All
 +  </Directory>
 +</VirtualHost>
 +</code>
apache/virtualhosts.1306483611.txt.gz · 最終更新: 2025/02/16 13:50 (外部編集)