[SOLVED] Add Google Translate to page?
Posted: Thu May 27, 2010 2:21 pm
Hello CMSMSers,
I have seen there is a MLE version of CMSMS but I'm not totally comprehending how it functions (having to create duplicates of every page in every language you want?)
I simply want to use Google Translate, so I don't have to do any translating myself, but people can select what language is suitable for them.
IF SOMEONE HAS A BETTER/ SIMPLER IDEA, LET ME KNOW!!!
I know the translations won't be perfect, but it will be better than nothing. From using the Google Translate Tools & Resources page, Google gives me the code:
So, after my tag, I merely past that code into my template. For testing purposes, I didn't put ANYTHING within the of my document except for the above code from Google. After saving, I open up the URL to view the page, and this error message is the only thing that is displayed on the page:
string(113) "Smarty error: [in tpl_body:23 line 4]: syntax error: unrecognized tag 'new' (Smarty_Compiler.class.php, line 590)"
What is the best way to go about fixing this? Would be nice to have a simple way to translate from one language to the next in an instant without me, the english-only speaking american, having to do any translating.
Cheers!
I have seen there is a MLE version of CMSMS but I'm not totally comprehending how it functions (having to create duplicates of every page in every language you want?)
I simply want to use Google Translate, so I don't have to do any translating myself, but people can select what language is suitable for them.
IF SOMEONE HAS A BETTER/ SIMPLER IDEA, LET ME KNOW!!!
I know the translations won't be perfect, but it will be better than nothing. From using the Google Translate Tools & Resources page, Google gives me the code:
Code: Select all
<div id="google_translate_element"></div><__script__>
function googleTranslateElementInit() {
new google.translate.TranslateElement({
pageLanguage: 'en',
includedLanguages: 'es'
}, 'google_translate_element');
}
</__script><__script__ src="http://translate.google.com/translate_a/element.js?cb=googleTranslateElementInit"></__script>
string(113) "Smarty error: [in tpl_body:23 line 4]: syntax error: unrecognized tag 'new' (Smarty_Compiler.class.php, line 590)"
What is the best way to go about fixing this? Would be nice to have a simple way to translate from one language to the next in an instant without me, the english-only speaking american, having to do any translating.
Cheers!