You want to type "http://www.php.com" in your webbrowser and have it take you to localhost?
If so, you would have an entry in /etc/hosts that looks like: 127.0.0.1 www.php.com The virtual host directive looks fine to me, assuming you only want to connect on port 80. On 9/9/05, matt-nc <[EMAIL PROTECTED]> wrote: > I'm trying to set up a name-based virtual host for my own local development > and testing purposes. > > As instructed by the Apache2 documentation, I have put the following in the > config file (actually the Vhosts.conf which is linked to httpd2.conf by an > include): > > #Listen for virtual host requests on all IP addresses > NameVirtualHost *:80 > > <VirtualHost *:80> > DocumentRoot /home/amos/www/php > ServerName www.php.com > </VirtualHost> > > Now, I need to put an entry in the hosts file. > > Based on the above information, what should I add to the hosts file? > > As I recall, I think it only has one line at the moment: > > 127.0.0.1 > > If anyone can verify that what I've done so far is correct and what to do > next, it would be greatly appreciated. > > Thanks, > Matt > > > -- > TriLUG mailing list : http://www.trilug.org/mailman/listinfo/trilug > TriLUG Organizational FAQ : http://trilug.org/faq/ > TriLUG Member Services FAQ : http://members.trilug.org/services_faq/ > TriLUG PGP Keyring : http://trilug.org/~chrish/trilug.asc > -- TriLUG mailing list : http://www.trilug.org/mailman/listinfo/trilug TriLUG Organizational FAQ : http://trilug.org/faq/ TriLUG Member Services FAQ : http://members.trilug.org/services_faq/ TriLUG PGP Keyring : http://trilug.org/~chrish/trilug.asc
