I'm using MAMP.

My httpd.conf:

NameVirtualHost *

<VirtualHost *>
   DocumentRoot "/Applications/MAMP/htdocs"
   ServerName localhost
</VirtualHost>

<VirtualHost *>
   DocumentRoot "/Applications/MAMP/test"
   ServerName test
</VirtualHost>

My hosts:

127.0.0.1 localhost test

On my local machine I can access the htdocs folder with "localhost" and 127.0.0.1 and the test folder with "test".

When I feed the browser of another device in my local network with the IP Address I get the htdocs folder.

How to access the test folder from other devices in my local network?

link|improve this question
feedback

1 Answer

Link hostname test with LAN-IP, resolvable for other lan-hosts

Or create virthost with name equal to IP and symlink it's DocumentRoot to test folder

link|improve this answer
How to link hostname "test" to a LAN-IP? – Aron Woost Oct 21 '11 at 21:09
DNS for lan-ips or add to every hosts-file – Lazy Badger Oct 21 '11 at 22:37
Hosts files not an option. How to DNS for LAN-ips? – Aron Woost Oct 22 '11 at 8:06
Start DNS-server for LAN and add this server as first into resolvers list on every host – Lazy Badger Oct 22 '11 at 21:28
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.