Posted: Tue Oct 07, 2008 6:39 am Post subject: setting virtual host and virtual IP to virtual network card
If you have web hosting plan and you have your server for testing. You need same cofiguration for web hosting plan and your personal.
You need then virtual host configuration in apache web server.
1. This needs you to setup virtual host entry instead of using localhost.
2. You need virtual IP that can be configure through virtual network card and can assign your favorite ip or simple adding through TCP/IP.
Easy way to install http://www.ntkernel.com/w&p.php?id=32 and download this virtNet driver. Assign IP TCP/IP through after installing like 192.168.1.3
Assigning multiple IPs through TCP/IP
Network Properties-> Internet Protocol (TCP/IP) --> properties--> Advanced --> IP Setting --> Add
Add your desired IP like 192.168.1.3 or many
Ping this IP to test If working fine
3. Make entries in hosts file c:\winnt\system32\drivers\etc
or linux can be /etc/hosts
Open this hosts file in any text editor
If pinging successfully its resolving domain entries
Open apache/config/httpd.conf in any text editor
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for requests without a known
# server name.
DocumentRoot "C:\Apache Group\Apache2\htdocs\directory1\domain1"
CustomLog logs/domain1.com-access_log common
Check in browser after restart of apache web server