2011-05-26

multiple virtualhost in wampserver2

1. add this line to c:\windows\system32\drivers\etc\hosts
127.0.0.1 mysite.com

2. add this block to httpd.conf file:

NameVirtualHost 127.0.0.1
<virtualhost 127.0.0.1>
ServerName localhost
DocumentRoot "C:/wamp/www"
</VirtualHost>

<virtualhost 127.0.0.1>
ServerName mysite.com
DocumentRoot "C:\wamp\www\share\www"
</VirtualHost>




fo MAMP users, just add this

ServerName devshara
DocumentRoot "/Users/const/Dev/svn/sharamba/development/www"

Комментариев нет:

Отправить комментарий