Can you change the text on the Google Translator to display Translator instead of select language?
https://jsfiddle.net/ogp8xobz/2/
I have tried:
$('#google_translate_element').text("Translator");
$('#google_translate_element span').text("Translator");
答案 0 :(得分:2)
该元素(#google_translate_element)包含许多子元素,您正在寻找的文字位于#google_translate_element内div内div内的锚点内的span内。要正确地执行此操作,您应该只处理最后一个范围:
$($(" #google_translate_element .goog-te-menu-value span")[0]).html("this one?");