Export (0) Print
Expand All

Customizing the Web Widget

String Parameter

Description

from

Source language of the page.

settings

Translation “behavior” of the widget, default is manual however the user can always override the behavior which persists for the browser session.

  • =manual
  • – Translation is only invoked when the user clicks “go” on the widget.
  • =notify
  • – If the browser locale is different than the page and is a supported MT language then show the toolbar and offer to translate the page.
  • =auto
  • – If the browser locale is different than the page and is a supported MT language then kickoff translation automatically.
  • =preview
  • – The widget appears normally but all functionality is disabled. This is used on the adoption portal.

loc

Override the UI locale, default is according to the client’s browser accept-language setting. We accept any .NET supported language and fallback to English if it is something we do not localize to.

showLanguages

Comma delimited list of additional languages to show. For instance:

'/ajax/v3/widgetv3.ashx?siteData= ... &ctf;=True&from=en&showlanguages=fr,de,it'
We accept any valid .NET language however unless the API accepts it the page will not get translated. Note that it is possible to add languages whose names we do not localize in which case the language name will always appear in English.

hideLanguages

Comma delimited list of languages to hide. For instance:

'/ajax/v3/widgetv3.ashx?siteData= ... &ctf;=True&from=en&hidelanguages=fr,de,it'

defaultLanguage

Language code to override the default target language.

ui

Whether or not to show the launcher (true/false).

ctf

To enable or disable the CTF suggestions feature. 'noanon' prevents anonymous users from making suggestions (true/false/noanon).

languages

The list of languages to override the default language list.

category

Use this value as the category field for all API calls. For instance:

'/ajax/v3/widgetv3.ashx?siteData= ...&from=en&layout=ts&category=<category ID>

While it does not impact the widget snippet there is also a feature that triggers translation on any page hosting the widget by appending “#mstto=(target language)” to the page URL. Here’s an example: "http://blogs.msdn.com/b/translation/#mstto=ko".

Show:
© 2014 Microsoft