Google Translator in ASP .Net

Hi Guys,When you need to add Google Translator in you website the this Code will help you.
Capture
Copy paste the below code in .aspx page

<div style=”width: 100%; text-align: left; margin-top: 2px;”>
<div>
<h4 style=”margin: 2px 0px; padding: 0px;”>
View the page in another language</h4>
</div>
<div>
<asp:Panel ID=”Panel1″ runat=”server”>
<div class=”flt_r1″>
<div id=”google_translate_element”>
<div style=”” class=”skiptranslate goog-te-gadget”>
</div>
</div>
<span class=”smallbody”>
<script type=”text/javascript”>
//<![CDATA[
function googleTranslateElementInit() {
new google.translate.TranslateElement({
pageLanguage: ‘en’
}, ‘google_translate_element’);
}
//]]>
</script>
<script src=”http://translate.google.com/translate_a/element.js?cb=googleTranslateElementInit&#8221;
type=”text/javascript”>
</script>
</span>
</div>
</asp:Panel>
</div>
</div>

You can also change the setting from using following Link”

https://translate.google.com/manager/website

Advertisements