Saving downloaded zip file: cpgz file type
Keith Clarke
keith.clarke at clarkeandclarke.co.uk
Mon Jun 6 11:03:10 EDT 2011
Hi folks,
I'm downloading a zip file via a web service call - the file is embedded as a long string within the ...<result><zipFile> node of the XML file, accompanied by a set of nodes that name the (xml text) files that I should find within the zipped payload.
So, I save this string out to to disk with...
put revXMLNodeContents(tTree, tResultNode & "/zipFile/") into URL "file:package.zip"
This creates a zip file on disk OK, but when when I open the archive, instead of a list of files, I get a .cpgz file - and attempting to open this causes some weird recursion. (I get the same result if I use the URL 'binfile' prefix.)
What am I doing wrong here - am I using the correct syntax or failing to encode/decode for the zip file definition string?
Best,
Keith..
More information about the use-livecode
mailing list