Reputation: 511
I have uploaded my project on a web host and I use ftp to edit my code. The problem is that I added models using eloquent for my database and to get it work I have to download my project dans run php composer dump-autoload then re-upload. Otherwise its say class not found ... Doing this all the time is just heavy. Is there any other solution? My webhost does not have ssh or any thing to connect to the server. Neither I can use rsync like stuff. Maybe I should use an other framework than laravel4 to avoid using composer?
Upvotes: 15
Views: 11372
Reputation: 2308
I'm not sure, sometimes it works, sometimes not...
But I upload:
And I don't have a bootstrap/compiled.php
Upvotes: 0
Reputation: 2310
In your case, you should add your needed autoload directory to the ClassLoader::addDirectories array under /app/start/global.php. Laravel gives multiple ways to accomplish the same thing depending on your personal needs.
Upvotes: 9
Reputation: 6511
You can remove or not upload the bootstrap/compiled.php file. I'm not sure if this completely fixes your problem, because I'm not sure if dump-autoload generates multiple files.
[edit]An other approach is to work on your local machine and upload after you are finished.
Upvotes: 2