Google Translate on WordPress(.com)
Since scripts are not allowed on WordPress(.com) blogs, I was wondering whether there开发者_开发知识库 is a way to get the following Google Translate code to work on a WordPress (.com) blog via the Text widget? Thanks in advance.
<div id="google_translate_element"></div><script>
function googleTranslateElementInit() {
new google.translate.TranslateElement({
pageLanguage: 'en'
}, 'google_translate_element');
}
</script><script src="http://translate.google.com/translate_a/element.js?cb=googleTranslateElementInit"></script>
You can't run most JS on wordpress.com, but there seems to be a workaround to use Google Translate: http://en.forums.wordpress.com/topic/translation-widget?replies=20
You're making it too complicated -- you can just use html. Color coded explanation with a little story here:
http://conradcook.wordpress.com/2012/07/21/machine-translation-fail/
精彩评论