http://www.perlmonks.org?node_id=385547


in reply to Simple command line web server for running cgis.

Actually, its not that hard to edit the apache config file to do what you want. For example, assuming WinXP, just add something like the following to the end of your httpd.conf file:

<VirtualHost *:80> ServerName www.sandbox.laptop ServerAlias sandbox.laptop DocumentRoot "C:/www.sandbox.laptop/htdocs" DirectoryIndex index.pl index.html ScriptAlias /cgi-bin/ "C:/www.sandbox.laptop/htdocs/cgi-bin/" ScriptAlias /index.pl "C:/www.sandbox.laptop/htdocs/index.pl" </VirtualHost>

And then edit your hosts file (on WinXP its C:/WINDOWS/system32/drivers/etc/hosts) like:

127.0.0.1 localhost www.sandbox.laptop sandbox.laptop

HTH,

Anne