Trying to understand the inclusion of web.header's and their correct
placement. Here is the code:
class A:
def GET(self):
web.header("Content-Type", "text/html; charset=iso-8859-1")
print render.Home()
def POST(self):
i = web.input()
web.seeother('/B')
class B:
def GET(Self):
web.header("Content-Type", "text/html; charset=iso-8859-1")
web.header("Content-Type", "image/jpeg")
print render.Results()
In class B, the Results.html file includes the rendering of image
files with <img ...> statements, but:
- including both web.header("Content-Type", "text/html;
charset=iso-8859-1") and web.header("Content-Type", "image/jpeg")
doesn't work
- including just the image web.header("Content-Type", "image/jpeg")
doesn't work
- including just the text web.header("Content-Type", "text/html;
charset=iso-8859-1") works
What gives?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"web.py" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/webpy?hl=en
-~----------~----~----~----~------~----~------~--~---