18 Apr
2002
18 Apr
'02
10:01 p.m.
Richard Wesley writes:
I am not having any luck trying to download some script-generated text from a browser (IE5/Mac in this case). When I try the following in a python method:
request.RESPONSE.setHeader('Content-Disposition', 'attachment; filename=file.txt') print 'Hello, filesystem!' return printed
It might help to use RESPONSE.setHeader('Content-Type','application') in addition. Some browsers are known to ignore this header and stubbornly look at the filename. In this case, you might need to drop the ".txt" extension. Dieter