blob: ef05a6343c16a53eaad0e0e17daf65acdd7f6487 (
plain)
1
2
3
4
5
6
7
|
def main(request, response):
import datetime, os
srcpath = os.path.join(os.path.dirname(__file__), "well-formed.xml")
srcmoddt = datetime.datetime.fromtimestamp(os.path.getmtime(srcpath))
response.headers.set("Last-Modified", srcmoddt.strftime("%a, %d %b %Y %H:%M:%S GMT"))
response.headers.set("Content-Type", "application/xml")
return open(srcpath, "r").read()
|