WebElement.getText() function and utf8
问题 May i assume that for every web page the WebElement.getText() function does return utf8 Strings, or can it have other encodings? If there could be other encodings, how can i identify it and convert it to utf8? 回答1: I don't know no one good way(maybe if you like reflection, you can hack and rewrite) to do getText() return needed encoding. But in this Selenium web driver and multillanguage I wrote some way to encode String. 回答2: I don't think so. According to the API, getText() returns a String