Export (0) Print
Expand All
699 out of 791 rated this helpful - Rate this topic

Web Widget Customization API

Microsoft Translator V2

The Web Widget Customization API enables you to customize the Translator Web Widget for your specific needs. You can programmatically call the Translator Web Widget’s functions and listen on its events.

For example, you can create a custom “Translate” button that blends well with your site’s UI or even define a certain trigger for the Translator Web Widget. You may also want to define actions that occur after translation of your page is complete.

Endpoint


<script src="http://www.microsoftTranslator.com/ajax/v3/WidgetV3.ashx?siteData=ueOIGRSKkd965FeEGM5JtQ**" type="text/javascript"></script>
						

Methods

Name Description

Translate

Launches the Widget which translates the current page to the desired language. A callback function provides translation progress information.

RestoreOriginal

Restores the original text in every HTML element that has been translated. It also stops the translation if in progress.

GetLanguagesForTranslate

Returns a list of Language objects with localized names according to the locale parameter provided.

GetLanguagesForTranslateLocalized

Returns a list of Language objects in which each language name is localized in its own locale. E.g. English, Deutsch, العربية,…

GetAutoDetectedLanguage

The Widget can auto-detect the language of the page – this method returns a string containing the last automatically-detected language.


Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.