Skip to content

Latest commit

 

History

History
27 lines (17 loc) · 1003 Bytes

Readme.md

File metadata and controls

27 lines (17 loc) · 1003 Bytes

Translator services

Latest Version Software License Total Downloads

Services that can be used to translate strings

Install

The first thing you need to do is to install a HTTP client. Please read HTTPlug quickstart. When the client is installed you may install this package with composer by running:

composer require php-translation/translator

Intro

$translator = new Translator();
$translator->addTranslatorService(new GoogleTranslator('api_key'));

echo $translator->translate('apple', 'en', 'sv'); // "äpple"