1

I uploaded a new laravel 4 app and cannot figure out how to get it to work. I am not sure if it is something with the composer.json file or what. Here is the error I am getting:

>Warning: require(/home/flemzy/public_html/l/bootstrap/../vendor/autoload.php) [function.require]: failed to open stream: No such file or directory in /home/flemzy/public_html/l/bootstrap/autoload.php on line 17

>Fatal error: require() [function.require]: Failed opening required '/home/flemzy/public_html/l/bootstrap/../vendor/autoload.php' (include_path='.:/opt/php53/lib/php') in /home/flemzy/public_html/l/bootstrap/autoload.php on line 17

2 Answers 2

2

Where did you upload you Laravel app ? From you path it seems it is in your home folder ? Laravel should be placed on your server, and you should point your server path to Laravel public folder. There is a default .htaccess file in every Laravel instalation, which is ready for Apache. Also, after install, you should run composer install, in order to download all dependencies. That vendor/autoload.php file is a part of core framework, so that means that you didn't install all dependencies properly.

Sign up to request clarification or add additional context in comments.

3 Comments

'public' => DIR.'/../public', 'base' => DIR.'/..',
how do you run composer install after the app is installed on my root server.
Laravel is composed of two parts: application skeleton and core framework. You first install skeleton, and then comes core framework. It is done automatically by composer. When you run composer install in any given moment, it will fetch all dependencis from composer.lock file. Composer update will fetch composer.json file.
0

I have had similar messages / problems uploading laravel to a server subdirectory.

Laravel docs provide an alternate .htaccess file that fixed my problems.

Options +FollowSymLinks
RewriteEngine On

RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]

Copy / paste that into your .htaccess, replacing the old one. Laravel Docs

To use the command line if it's a composer issue, you can use SSH to access your laravel directory. If you're using windows you can use PuTTY for that, which has lots of tutorials and instructions online.

Laravel SSH docs

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.