Support the ongoing development of Laravel.io →
Requests
Last updated 2 years ago.
0

Try this php artisan dump-autoload” and “composer dump-autoload”

Last updated 2 years ago.
0

Hi trololosha4real,

Try adding in your app/start/global.php the following line:

ClassLoader::addDirectories(array(

    app_path().'/commands',
    app_path().'/controllers',
    app_path().'/controllers/Site',
    ....
));

Or try using composer.json file and adding the same folder to autoload section:

"autoload": {
    "classmap": [
        "app/commands",
        "app/controllers",
        "app/controllers/Site",
        "app/models",
        "app/database/migrations",
        "app/database/seeds",
        "app/tests/TestCase.php"
    ]
},

Then you need to use php artisan dump-autoload CLI command.

Try and comment us.

Hope it helps you.

Last updated 2 years ago.
0

Thanks a lot guys. My mistake was in prefix, i thought it tells to load controller from site directory....

Last updated 2 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.