I kept working on this and created an updated example switching between two languages Chinese and English if you need more than two languages you would have to hide all languages and show only the one selected instead of using toggle the way I am.
What is computer code javascript xml html any programming language. Any programming language Get the answers you need now. It also checks their geolocation if their browser supports it automatically setting the language.