0

I have some virtual-host and I can access it on the PC that has the server intalled. But I have others Pc and I want to access via the domain name.

I just can access to the server configuration page changing the statement "Require local" to "Require all granted". This only allow me to access through the ip address.

<VirtualHost *:80>
    ServerName localhost
    DocumentRoot D:/wamp64/www
    <Directory  "D:/wamp64/www/">
        Options +Indexes +Includes +FollowSymLinks +MultiViews
        AllowOverride All
        Require all granted
    </Directory>
</VirtualHost>

<VirtualHost *:80>
    ServerName laravel5.1.app
    DocumentRoot "d:/wamp64/www/laravel5_1/public"
    <Directory  "d:/wamp64/www/laravel5_1/public/">
        Options +Indexes +Includes +FollowSymLinks +MultiViews
        AllowOverride All
        Require all granted
    </Directory>
</VirtualHost>
juanmiguel431
  • 79
  • 2
  • 11

1 Answers1

0

To access the site using your domain names you must tell each of the other PC's where to find the domain name.

So you either need a local DNS Server or you edit the HOSTS file on each PC that you want to access the site from by adding something like this to the other PC's HOSTS

192.168.1.100 laravel5.1.app

Assuming your WAMPServer (Apache) is running on ip address 192.168.1.100

RiggsFolly
  • 93,638
  • 21
  • 103
  • 149
  • Thanks @RiggsFolly , as you said, I had to install a Dns Server instead of edit all Hosts file. I installed Simple DNS Plus running on windows 10. Do you have other option without cost than that? – juanmiguel431 Feb 24 '17 at 21:04