Having opted for the "Automatic" version of Google Translate Widget, I expected not to see the "Select Language" dropdown if my browser was the same language as the site. However, I see it all the time no matter what I set the html lang attribute to or what I set my browsers preferred language to. I have also noticed that it doesn't seem to make any difference whether the meta "google-translate-customization" tag is there or not, the widget is always in view.
I'd like the site to just be translated if the users browser isn't set to English.
Any advice would be appreciated.
Code used:-
In head:-
<meta name="google-translate-customization" content="6bb255d109276506-b73cb06230e6b6c0-gbb2acb9bc95b4a11-12"></meta>
In Body:-
<div id="google_translate_element"></div>
<script>
function googleTranslateElementInit() {
new google.translate.TranslateElement({pageLanguage: 'en', layout: google.translate.TranslateElement.FloatPosition.TOP_LEFT}, 'google_translate_element');
}
</script>
<script src="//translate.google.com/translate_a/element.js?cb=googleTranslateElementInit"></script>