I was looking for a way to change the public's folder name in laravel 5.1, since my host only allows me to use a htdocs folder.
相关问题
- Laravel Option Select - Default Issue
- Laravel 5.1 MethodNotAllowedHttpException on store
- Laravel - Implicit route model binding with soft d
- laravel : php artisan suddenly stop working
- How to execute MYSQL query in laravel?
相关文章
- laravel create model from custom stub when using p
- send redirect and setting cookie, using laravel 5
- How to send parameters to queues?
- Bcrypt vs Hash in laravel
- Laravel: What's the advantage of using the ass
- How to make public folder as root in Laravel?
- Input file in laravel 5.2?
- What is the difference between Session::set and Se
I followed these steps, mentioned here : https://laracasts.com/discuss/channels/general-discussion/where-do-you-set-public-directory-laravel-5 :
in
bootstrap/app.php
, addThen, in
/server.php
, change the two occurences ofpublic
tohtdocs
(Or whatever you wan to use).I sincerely hope that'll work in every situation.
Edit 2016-10-18 :
I recently had to do the same, but this time my host allowed me to delete the "htdocs" folder (And I had a ssh access) :
ln -s public htdocs
This is how i did it.. updates and other things work perfectly till now..
make a new folder on root.. and move all folders inside it(ill call it "myfolder" for example).. then move files inside public folder to root.. so it should look like..
so open server.php with text editor and replace with this code..
then on index.php
then go to "/myfolder/bootstrap/autoload.php"..
and app.php inside same folder
Works well for me on development and production environment..