-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
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
API Key in config.yml #7
Comments
I confirm than a simple composer update should fix the issue for Languages method. You should have: ▶ composer update eko/googletranslatebundle
Loading composer repositories with package information
Updating dependencies (including require-dev)
- Updating eko/googletranslatebundle dev-master (ac90d27 => dfd84c9)
Checking out dfd84c95150f5e917078f93cbb5e857868380ec0 I just tested your code (with hardcoded values) here: $translator = $this->get('eko.google_translate.translator');
$value = $translator->translate('test', 'fr', 'en'); and here is the result (because I do not have an API key actually, so it's normal): Client error response [url] https://www.googleapis.com/language/translate/v2?key=fake-api-key&q=test&source=en&target=fr [status code] 400 [reason phrase] Bad Request However, I cannot reproduce your issue. Can you please paste me the result of the following command: Thank you |
The composer show result is: name : eko/googletranslatebundle autoload requires If it helps below is the stack trace: Stack Trace
|
You're not up-to-date with latest tag commits. Can you please run the following command and paste me the result? composer update eko/googletranslatebundle --prefer-source Thank you |
$ composer update eko/googletranslatebundle --prefer-source In the composer.json I have the require on the bundle as: |
Alright, I just released a tag |
awesome! that worked perfectly! thank you so much :) |
Great, you're welcome, sorry for this issue and happy translating ;) Do not hesitate if you have other issues. Thank you |
So I should just do a composer update right? The error still occurs.
My config.yml entry is like this:
eko_google_translate:
api_key: server_public_api_key_generated_in_google_developers_console
My controller code is:
The text was updated successfully, but these errors were encountered: