We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I used following code , I need to translation multiple words at a time.
require_once './vendor/autoload.php'; use Yandex\Translate\Translator; use Yandex\Translate\Exception; try { $translator = new Translator('keyansdnaksndjkjsajk'); $translation = $translator->translate(array('banana','apple'), 'en-ru'); echo "<pre>"; print_r($translation); echo $translation->getSourceLanguage(); // en echo $translation->getResultLanguage(); // ru } catch (Exception $e) { // handle exception }
But result is not having translated words. It is working for only single word not array
Yandex\Translate\Translation Object ( [source:protected] => Array ( [0] => banana [1] => apple ) [result:protected] => Array ( ) [language:protected] => Array ( [0] => en [1] => ru ) )
The text was updated successfully, but these errors were encountered:
I fix this bug in pull-reqeust #7 Or in my fork of this library https://github.com/berejant/translate-api
Sorry, something went wrong.
No branches or pull requests
I used following code , I need to translation multiple words at a time.
But result is not having translated words. It is working for only single word not array
The text was updated successfully, but these errors were encountered: