WPF WebBrowser NavigateToString vs NavigateToStream (hebrew/non-utf8 encodings)
When I use WPF WebBrowser's NavigateToString method to display UTF8 html (with hebrew text in it) it's displayed perfectly.
However, when I try to use the NavigateToString to display html with hebrew text in it in a non-utf8 encoding (CodePage 1255 to be exact) the hebrew is messed up.
I checked the cp1255 string in Visual Studio's debugger and it looks great, and also when I save the source of the web browser's contents and open it with an external browser it looks great.
If I use the NavigateTo开发者_开发问答Stream method instead of the NavigateToString method it works great.
What's the problem with the NavigateToString? am I doing something wrong?
NavigateToString= NavigateToStream + UTF8NoBOM Use NavigateToStream and make sure you have the correct encoding in the stream data.
精彩评论