New Message: Re: Returning data rather than html

webmaster at userland.com webmaster at userland.com
Wed Jun 29 16:50:43 CDT 2005


A new message was posted:

Address: http://frontier.userland.com/discuss/msgReader$14139

By: Chris Bunch (chris.bunch at ndm.ox.ac.uk)

That's great, Sam - many thanks

scriptError( "!return" ) is what I was fishing for. Here (following your lines) is the simple "proof of concept" i need for my users:

local (pta=html.getPageTableAddress());
pta^.responseBody ="Date\tDetails\r\25/12/05\tChristmas Day\r"; //trivial example
pta^.responseHeaders.["Content-Type"] = "text/plain";
pta^.responseHeaders.["Last-Modified"] = date.netStandardString( clock.now ());
scriptError( "!return" )

This allows my users to simply copy and paste the output into Excel, which will make them happy bunnies!

This is a Manila site.. http://manila.userland.com/.




More information about the Manila-Server mailing list