alert ('hello world');
alert('Zarys gramatyki por¢wnawczej jezyk¢w slowianskich');I then linked this into a (very) basic HTML page<html xmlns="http://www.w3.org/1999/xhtml" >
</html>so that on pageload 2 alert boxes are displayed, one saying 'Hello World' and the one saying 'Zarys gramatyki por¢wnawczej jezyk¢w slowianskich'.Unfortunately what is displayed instead is:
which isn't exactly what I had in mind.I opened the file in Notepad++ (my text editor of choice) to take a look at the file type and it is, as I'd expected, saved as ANSI, not UTF-8 or UTF-16
I used Notepad++'s menu item Format -> Convert to UTF-8 to convert this file from ANSI into UTF-8, and then re-ran my test and all works correctly as expected. Hurrah!I then repeated this using VS2008 and found that this is one of the fixes over VS2005.So, the alert now correctly displays:
and when opened in Notepad++ the file is now, correctly, UTF-8.