Laravel setup failed to open stream

You can simply use (I’ve same setup for all of my projects) in httpd-vhosts.conf file

<VirtualHost iproject.dev>
    DocumentRoot "C:/xampp/htdocs/iProject/public"
    ServerName iproject.dev
</VirtualHost>

Also, add the following line in you C:\Windows\System32\drivers\etc\hosts file

127.0.0.2      iproject.dev # 127.0.0.2 could be 127.0.0.3 or ...4/...5

For example, this is a part of my hosts file in win-7

127.0.0.1       localhost
127.0.0.1       127.0.0.1
127.0.0.2       alimsearch.dev # alimsearch.co.uk
127.0.0.3       laravel4.dev
# ...

And part of my httpd-vhosts.conf file

<VirtualHost alimsearch.dev>
    DocumentRoot "D:/xampp/htdocs/alimsearch/public"
    ServerName alimsearch.dev
</VirtualHost>

<VirtualHost laravel4.dev>
    DocumentRoot "D:/xampp/htdocs/laravel4/public"
    ServerName laravel4.dev
</VirtualHost>

Leave a Comment