Translate-GO
- Translate-GO is a powerful and user-friendly website automatic translation tool developed using the Go language. It is specifically designed to help websites achieve rapid internationalization, with its most notable feature being that it requires no complex modifications to the existing system. Specifically, translate-go does not require database changes or front-end and back-end program structure alterations, significantly simplifying the process of adding multilingual support.
- By simply incorporating a JavaScript file into your website, translate-go allows you to quickly enable internationalization, whether your project is based on traditional JavaScript or utilizes modern front-end frameworks like Vue.js. This non-intrusive design makes initial setup extremely easy and helps maintain the integrity and stability of the website structure during the internationalization process.
- Moreover, translate-go is designed with compatibility in mind for different development approaches. It not only supports classical development modes but can also seamlessly integrate with popular contemporary frameworks. This makes it particularly suitable for websites looking to expand into international markets in a short amount of time, providing an efficient and economical internationalization solution.
-
edit your index.html file, add the following code to the body tag
<script src="https://public.cmche.com/js/translate.mini.js"></script> <script> translate.language.setLocale('english'); // set the default language translate.service.use('client.edge'); // set the translation service translate.listener.start(); // listen for dynamic content changes window.onload = function () { translate.execute(); // execute the translation } </script>
-
edit your menu.html file, add the following code
<div class="menu"> <a href="javascript:window.translate.changeLanguage('english');">English</a> <a href="javascript:window.translate.changeLanguage('chinese_simplified');">中文</a> <a href="javascript:window.translate.changeLanguage('japanese');">しろうと</a> </div>