Duplicate an XML file with Cold Fusion 8

2008-01-18 Thread Don L
This is what I want to do: save/duplicate a copy of an uploaded XML file in case of need. Techniques that I've tried to no avail. Necessary bla bla: The interface: (It's an HTML form that provides mechnism to upload an XML file, like input type=file name=UploadXmlFile ) The process: a) check

Re: Duplicate an XML file with Cold Fusion 8

2008-01-18 Thread Don L
Tod and Will, Sorry, we're not on the same page yet, the source XML file is to be uploaded by a user, so, we don't have a file sitting on the server box yet. And yes, I've also tried something like the following to no avail. cfset tmpFileName = tmpFile#Right(Rand(),2)# cffile action = write

RE: Duplicate an XML file with Cold Fusion 8

2008-01-18 Thread Will Swain
January 2008 15:31 To: CF-Talk Subject: Duplicate an XML file with Cold Fusion 8 This is what I want to do: save/duplicate a copy of an uploaded XML file in case of need. Techniques that I've tried to no avail. Necessary bla bla: The interface: (It's an HTML form that provides mechnism

Re: Duplicate an XML file with Cold Fusion 8

2008-01-18 Thread Todd
Don? It's a file. Stop thinking XML for a second and start thinking of a file. fileCopy()? On Jan 18, 2008 10:30 AM, Don L [EMAIL PROTECTED] wrote: This is what I want to do: save/duplicate a copy of an uploaded XML file in case of need. Techniques that I've tried to no avail. Necessary

Re: Duplicate an XML file with Cold Fusion 8

2008-01-18 Thread Todd
Don, When you're looking for help, you can't really short-hand. I have to assume the code posted is what I'm given. :) Anyway, xml file is still a text file, correct? It can be read like a text file and backed up to any medium you want. This whole thread is confusing me a little because you

Re: Duplicate an XML file with Cold Fusion 8

2008-01-18 Thread Don L
Todd, You misunderstood what I intended to do. form-wise, of course, for a file upload, it's like ... that's HTML 101 ... cfform action=#CGI.script_name# method=post enctype=multipart/form-data /cfform I was using short-hand... Another technique that I haven't tried yet but will work, that

Re: Duplicate an XML file with Cold Fusion 8

2008-01-18 Thread Todd
Don, There's no multi-part form there? Where's your cffile action=upload You're writing before you even get to the server. Again, it's a file. Once it's on the server, you can treat it like any other file. Quit doing XML functions on it unless you're trying to validate that it's an XML file,

Re: Duplicate an XML file with Cold Fusion 8

2008-01-18 Thread Don L
Todd, Sorry for the confusion, yes, I'll make problem statement clearer down the road... It's resolved. When the first two techniques failed, and third one of creating a backup file approach did not work out neither, that technique failure was caused by my own neglect, I should have used the