Closed grandeljay closed 1 year ago
The namespace is DeepL
, not Deepl
, so
$translator = new \Deepl\Translator(DEEPL_API_KEY);
should be
$translator = new \DeepL\Translator(DEEPL_API_KEY);
Omg, I am so sorry 😭
Thank you for responding, I really appreciate it!
All good, we've all been there :)
Hello,
I'm guessing this is not directly related to this library but I am experiencing some very strange behaviour and was hoping you could still help me.
I am working on a WordPress plugin with the following code:
Without manually requiring the DeepL class I get the following error:
Composer commands I have run in an attempt to fix this:
composer require deeplcom/deepl-php
composer install
composer dump-autoload
My composer.json:
I'm probably making an obvious mistake but can't see what. Please help!
Thanks in advance!