Issue
By default, Laravel project is run from public directory, for this I must enter URL like as:
http://localhost/public/
How to configure Laravel that website will be appeared from: http://localhost/
?
Solution
•Go to mainproject/public>>
a. .htacess
b. favicon.ico
c. index.php
d. robots.txt
e. web.config
1.cut these 5 files from the public folder, and then paste on the main project folder that’s means out side of public folder… mainproject/files
2.Next after paste ,open index.php ,modify
•require __DIR__.'/…/bootstrap/autoload.php'; to
•require __DIR__.'/bootstrap/autoload.php';
modify
$app = require_once DIR.'/../bootstrap/app.php'; to
$app = require_once DIR.'/bootstrap/app.php';
you can also watch this video for better understanding----------------
https://www.youtube.com/watch?v=GboCYqEbKN0
Answered By - Borna
0 Comments:
Post a Comment
Note: Only a member of this blog may post a comment.