Errin when executing a cgi script that sets a cookie in the browser

Νικόλαος Κούρας nikos.gr33k at gmail.com
Thu Jun 6 15:30:59 EDT 2013


Τη Πέμπτη, 6 Ιουνίου 2013 10:26:08 μ.μ. UTC+3, ο χρήστης Lele Gaifax έγραψε:

> Did you tried running that by a standalone Python interpreter? Did you
 
> notice something strange, something like that an empty line is missing
> between headers and body?

No, nothing at all.
Two '/n/n' are not required. Months now the way i'm printing headers is by:

print( '''Content-type: text/html; charset=utf-8\n''' ) 

and the scripts owrk correctly in browser and in python interpreter too.



More information about the Python-list mailing list