I am very new to laravel, I am using windows 7 OS. I have a PHP website made on laravel 5 which I want to run on my browser. I have gone through the videos and the various website on "How to run laravel 5 project on browser" but unfortunately I failed to run my project on the browser. I am using XAMPP and below is my Virtual Hosts file of apache. My localhost port is 7000.
<VirtualHost *:7000>
DocumentRoot "C:\xampp2\htdocs\basicwebsite\public"
ServerName basicwebsite.com
</VirtualHost>
And inside the hosts file within the system32 folder I have put the following line
127.0.0.1 basicwebsite.com
When I am trying to run it on my browser it gives me an error
"This site can’t be reached
basciwebsite.com refused to connect."
Any help is welcome.
check below points -
1.) .env file should have APP_KEY 2.) have you created "storage/views" , "storage/cache"
When I'm developing locally with Laravel, I simply execute php artisan serve on the terminal. I can then run it on http://localhost:8000
Try This:
<VirtualHost *:7000>
DocumentRoot "C:/xampp2/htdocs/basicwebsite/public"
ServerName basicwebsite.com
<Directory "C:/xampp2/htdocs/basicwebsite">
</Directory>
</VirtualHost>
Try using something other than basicwebsite.com in the servername, Maybe use basicwebsite.local
Explanation: .com is widely used therefore using something different should do the trick, try http://nameofwebsite.local (doesn't have to be .local, can be anything really but not .com or .net for example)