I use Xampp to give me a localhost environment for testing PHP. I recently set up a virtual host in the httpd-vhosts.conf file of xampp so that I could seperate projects into their own domain name space - my virtual host description is below:
NameVirtualHost * <VirtualHost *> DocumentRoot "C:\xampp\xampp\htdocs" ServerName localhost </VirtualHost> <VirtualHost *> DocumentRoot "C:\xampp\xampp\htdocs\sales_dev2" ServerName sales.dev <Directory "C:\xampp\xampp\htdocs\sales_dev2"> Order allow,deny Allow from all </Directory> </VirtualHost> <VirtualHost *> DocumentRoot "C:\xampp\xampp\htdocs\opencart" ServerName opencart.local <Directory "C:\xampp\xampp\htdocs\opencart"> Order allow,deny Allow from all </Directory> </VirtualHost>
I also edited my hosts file so that each of the ServerName's described would resolve to 127.0.0.1.
This setup works fine in FireFox and IE, but in Chrome the ServerName's that do not follow a recognised TLD are instead resolving to a google search for that string (google search 'opencart.local' for instance)
Can anyone please advise on how to resolve this?