I have a problem when deploy website build on laravel 5 into VPS server, but on local machine it work fine.
My page is http://easyway.vn/ current page display blank
it means that your Laravel Application Can't Find the public folder.
I got it to work by
changing :
chdir($this->laravel->publicPath());
in :
vendor/laravel/framework/src/Illuminate/Foundation/Console/ServeCommand.php
To :
chdir('/');
this error appears when you rename the public
folder.
Never edit files in vendor folder. After composer update or fresh install you will lose your changes.
A better solution is to edit bootstrap/app.php and place this snippet before the return statement.
$app->bind('path.public', function() {
return base_path() . '/web';
});
`chdir($this->laravel->publicPath());`
change to
chdir('/');
2.Step two Change these two paths in your_public_folder/index.php
require __DIR__.'/../your_app/bootstrap/autoload.php';
$app = require_once __DIR__.'/../your_app/bootstrap/app.php';
3.Step three Change public path in your_app/server.php
if ($uri !== '/' && file_exists(__DIR__.'/../public_html/'.$uri)) {
return false;
}
require_once __DIR__.'/../public_html/index.php';
Note: Change these path according to your App's new folder structure.