ローカル開発用に XAMPP をインストールしており、プロジェクトごとにサブドメインを作成したいと考えています。私のapache vhosts構成では、これを入れました:
<VirtualHost localhost:80>
DocumentRoot C:/xampp/htdocs/
ServerName localhost
ServerAdmin admin@localhost
</VirtualHost>
<VirtualHost nexus.localhost:80>
DocumentRoot C:/xampp/htdocs/nexus/
ServerName nexus.localhost
ServerAdmin admin@nexus.localhost
</VirtualHost>
そして、私のWindowsホストファイルでは:
# development
127.0.0.1 localhost
127.0.0.1 nexus.localhost
localhost は通常どおり動作します。のように、私が行けばhttp://localhost/project_nameすべてうまくいきます。ただし、に移動するhttp://nexus.localhost/と、Object not found!エラーが発生します。
ここで何が問題なのですか?ありがとうございました。