how to install laravel on hostinger server/ any other free hosting server. I had learned and done working codes in localhost. But i would like to run it on a real server.
Laravel Version : 5
PHP Version Server :5.5.35
1) I had copied the full laravel code to "/home/< username >/"
2) copied the files in /home//laravel/public to /home/< username >/public_html
But it shows an error.
Fatal error: require(): Failed opening required '/home//public_html/../bootstrap/autoload.php' (include_path='.:/opt/php-5.5/pear') in /home//public_html/index.php on line 22
Answer : Use Heroku Server as @lciamp Suggested in the comment
Clarification :
Please suggest me a list of Payed Servers which support Laravel Framework
Since you have SSH access do this:
Filesystem
cd /home/< username >
public_html
folderrm -rf public_html
public
topublic_html
ln -s /home/< username >/public /home/< username >/public_html
composer install
chmod -R 755 *
chmod -R 777 storage/ bootstrap/cache/
Checklist
.htaccess
files.**In Case of a Limited Shell Environment
vendor
folder with everything else./home/< username >/
upload it to/home/< username >/public_html
.Modify your
/home/< username >/public_html/.htaccess
to redirect all requests to thepublic
subfolder.Make sure you have the proper
/home/< username >/public_html/public/.htaccess
(GitHub).After you copy the code to your hosting server, you need to install the
composer
packages required to run Laravel. You can do this usingcomposer install
(providing thatcomposer
is installed). Otherwise, you need to installcomposer
first.