ronster/bing-translation

There is no license information available for the latest version (dev-master) of this package.

Port of the Bing Translate PHP wrapper for laravel 4

dev-master 2013-11-08 10:58 UTC

This package is not auto-updated.

Last update: 2024-05-07 01:28:27 UTC


README

Installation

Install this package through Composer. To your composer.json file, add:

"require-dev": {
	"ronster/bing-translation": "dev-master"
}

Next, run composer update to download it.

Finally, add the service provider to app/config/app.php, within the providers array.

'providers' => array(
	// ...

	'Ronster\BingTranslation\BingTranslationServiceProvider'
)

Configuration

Run php artisan config:publish Ronster/bingtranslation to publish the package config file. Add your API key and your done.

Usage

This package is a laravel 4 port of the Microsoft Bing Translation PHP wrapper. Instructions can be found here: Microsoft Bing Translation PHP wrapper

Example

$text = 'Hello world!';
$translatedText = Bing::translate( $text, "en", "nl" );
dd($translatedText);