K
K
kkolorid2019-06-16 19:26:32
Yii
kkolorid, 2019-06-16 19:26:32

Connecting a class from vendor to Yii2 - Class not found?

I installed a bun from github - https://github.com/Clarifai/clarifai-php
Everything seems to be uploaded to the server, the editor sees the paths, highlights the names of the constructor parameters... And Yii gives out "Class not found". How it is?
There was already such a problem with the extension, I connected it directly, I don’t remember exactly what I did, but it worked. Now he doesn't want to

$client = new \\PhpFanatic\clarifAI\ImageClient([key]);

Everything seems to be the same:
"autoload": {
        "psr-4": {
            "PhpFanatic\\clarifAI\\": "src"
        }
    }

I don't understand how?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry, 2019-06-16
@kkolorid

Good evening.
1) What does your question have to do with "github"
2) Did you update the autoloader after you made the entry in composer.json? If not - do composer dump-autoload
it 3) Or take a package from packagist.com , install via composer and don't suffer.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question