I created a very simple script, testing it out with web browser.<br><br># -*- coding: utf-8 -*-<br>import sys<br>sys.getdefaultencoding()<br> <br>f = '¿'<br>print "Content-Type: text/plain;charset=utf-8"<br>
print f<br><br> The moment I have an Asian text in my file (without doing anything to it at all) I always get a 502 error - web server received an invalid response. The script prints out just fine if I use python own IDLE however.<br>
<br>The file was utf-8 encoded and setdefaultencoding is also utf-8. Testing out on windows server 2008 R2 IIS 7.5.<br><br>Any help greatly appreciate!<br>