Hi.
I am using WAMP which including the following:
PHP 5...
MySQL 5...
Apache 2...
I want to create IP-Based VirtualHost, therefore I did the following:
1. add "Microsoft Loopback Adapter", and I assign two IP on that.
2. Create two folders named (host1, host2) in my root directory which is www. and for sure inside those two folders I place some php files.
3. and I add the following in my httpd.conf
#********************************* VIRTUAL HOSTING BY IP
Listen 127.0.0.1:8081
Listen 192.168.1.1:8081
Listen 192.168.1.2:8081
NameVirtualHost 192.168.1.1:8081
NameVirtualHost 192.168.1.2:8081
<VirtualHost 192.168.1.1:8081>
DocumentRoot "C:\wamp\www\host1"
ServerName host1.com
</VirtualHost>
<VirtualHost 192.168.1.2:8081>
DocumentRoot "C:\wamp\www\host2"
ServerName host2.com
</VirtualHost>
#********************************* VIRTUAL HOSTING BY IP
4. and then I added the following in the hosts file
127.0.0.1 localhost
192.168.1.1 host1.com
192.168.1.2 host2.com
5. open the browser and type the following address
http://host1.com:8081/
I get the following error:
[B]Forbidden[/B]
You don't have permission to access / on this server.
I don't know what to do? anyone please guide me
P.S:
I am working on my own computer, it means I am not in any Network or on the Internet, so I did not use the real computer adapter, because it is unplugged, and therefore I add Microsoft Loopback Adapter