Program to Translate English Text To Bengali through Google Transliterate API

Posted by Rajnilari2015 under JavaScript category on | Points: 40 | Views : 29


<title>Translate English To Bengali through Google API</title>

<script type="text/javascript" src=""></script>

<script type="text/javascript">

// Load the Google Transliterate API
google.load("elements", "1", {packages: "transliteration"});


function OnLoad(chooseLanguage) {

//Make the options
var options = {
sourceLanguage: google.elements.transliteration.LanguageCode.ENGLISH,

destinationLanguage: [google.elements.transliteration.LanguageCode.BENGALI],

shortcutKey: 'ctrl+g',

transliterationEnabled: true

// Create an instance of TransliterationControl with the needed options.
var control = new google.elements.transliteration.TransliterationControl(options);

// Enable transliteration in the textbox with id 'txtInput'.

} //end onLoad function

//Invoking the onLoad handler



<body> Type In English and the code will be translated in Bengali: <input size="40" type="text" id="txtInput"/></body>

Comments or Responses

Login to post response