Coldfusion 9 XML creation and HTML after
Here is what I am running into. I have a web form that takes in the info I need. I process the form on the next page and it creates an XML document that I need (which is being created successfully). I need to display something back to the end user telling them it's been created. After my end tag /cfprocessingdirective if I write any text it throws back the errors that there is something after that end tag... How do I create my XML document and still display something back to the end user (or if need be, use a cflocation to get them to an acknowledgement page? The error that comes back in a red box: This page contains the following errors: error on line 26 at column 1: Extra content at the end of the document Below is a rendering of the page up to the first error. Ken ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:344499 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Coldfusion 9 XML creation and HTML after
can you post the code here http://pastebin.com/ http://pastebin.com/ On Fri, May 13, 2011 at 5:43 PM, Ken Hammond khamm...@saleminc.com wrote: Here is what I am running into. I have a web form that takes in the info I need. I process the form on the next page and it creates an XML document that I need (which is being created successfully). I need to display something back to the end user telling them it's been created. After my end tag /cfprocessingdirective if I write any text it throws back the errors that there is something after that end tag... How do I create my XML document and still display something back to the end user (or if need be, use a cflocation to get them to an acknowledgement page? The error that comes back in a red box: This page contains the following errors: error on line 26 at column 1: Extra content at the end of the document Below is a rendering of the page up to the first error. Ken ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:344502 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Coldfusion 9 XML creation and HTML after
Here is what I am running into. I have a web form that takes in the info I need. I process the form on the next page and it creates an XML document that I need (which is being created successfully). I need to display something back to the end user telling them it's been created. After my end tag /cfprocessingdirective if I write any text it throws back the errors that there is something after that end tag... How do I create my XML document and still display something back to the end user (or if need be, use a cflocation to get them to an acknowledgement page? You can't output both XML and HTML within a single HTTP response. Well, you can, but the client won't know what to do with it. If you need to generate XML, that typically isn't going to be returned directly to the browser, because the browser won't know what to do with it. So, you will have to take a slightly different approach. There are a couple of ways you could go. You could notify the user before generating the XML, then redirect the user to the XML generation. Or, you could generate the XML and store it in a variable or file, then allow the user to click a link to generate the appropriate XML response. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ http://training.figleaf.com/ Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on GSA Schedule, and provides the highest caliber vendor-authorized instruction at our training centers, online, or on ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:344503 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Coldfusion 9 XML creation and HTML after
my guess is that you have answered your question by saying that you could use a cflocation tag. Alternatively, if you trust your xml scrip to always create the xml document without errors, you may use a prompt to display your activity status just before you use the xml script. Best Regrads, Chuka I.W. Anene Chief Software Eng./CEO Quorium Solutions www.quorium.org +234 70 3269 6113 +234 80 9530 7257 +234 1 881 2777 From: Ken Hammond khamm...@saleminc.com To: cf-talk cf-talk@houseoffusion.com Sent: Fri, May 13, 2011 4:43:44 PM Subject: Coldfusion 9 XML creation and HTML after Here is what I am running into. I have a web form that takes in the info I need. I process the form on the next page and it creates an XML document that I need (which is being created successfully). I need to display something back to the end user telling them it's been created. After my end tag /cfprocessingdirective if I write any text it throws back the errors that there is something after that end tag... How do I create my XML document and still display something back to the end user (or if need be, use a cflocation to get them to an acknowledgement page? The error that comes back in a red box: This page contains the following errors: error on line 26 at column 1: Extra content at the end of the document Below is a rendering of the page up to the first error. Ken ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:344505 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Coldfusion and XML
I am outputting an XML document via Coldfusion, at present I have the data from this file returning on the browser. However I can I get this data to write to a text file comma seperated ..CSV file that the user can save ?? Any ideas, and is it achieveable in Coldfusion or would I have to write a separate XSL stylesheet such as --- XSL SNIPPET--- xsl:output method=text/ xsl:template match=BuildingRecord xsl:value-of select=normalize-space(SchemeUniqueRecordIdentifier)/, xsl:value-of select=normalize-space(CompetentPerson/PersonRegistrationNumber)/, - My current COLDFUSION code is below !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.0 Transitional//EN html head titleTEST XML/title /head body cffile action=upload filefield=UploadFile destination=#GetTempDirectory()# nameconflict=overwrite cffile action=read file=#GetTempDirectory()##cffile.serverfile# variable=myxml cfset mydoc=XmlParse(myxml) CFSET BuildingRecordset = mydoc.XMLRoot CFOUTPUT strong#mydoc.BuildingRecordset.SchemeName[1].XMLText# - Building Control/strong p/p Local Authority Code - #mydoc.BuildingRecordset.LocalAuthorityCode[1].XMLText# p/p Name = #mydoc.BuildingRecordset.BuildingRecord[1].CompetentPerson[1].PersonRegi strationNumber[1].XMLText# /CFOUTPUT /body /html ~| Discover CFTicket - The leading ColdFusion Help Desk and Trouble Ticket application http://www.houseoffusion.com/banners/view.cfm?bannerid=48 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:193592 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
I am receiving the following error when parsing an XML doc, any ideas why it is looking for p etc from the code below ? Ian -- Error Occurred While Processing Request Invalid CFML construct found on line 22 at column 1. ColdFusion was looking at the following text:plt;/ppThe CFML compiler was processing:ullt; marks the beginning of a ColdFusion tag.Did you mean LT or LTE?lia cfset tag beginning on line 20, column 2./ul The error occurred in \testpages\parse2.cfm: line 22 20 : cfset mydoc=XmlParse(myxml) 21 : 22 : cfset scheme=#mydoc.buildingrecordset.buildingrecord.XMLAttributes.SchemeUniqu eRecordIdentifier# 23 : 24 : ---CODE !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.0 Transitional//EN html head titleTEST XML/title /head body cffile action=upload filefield=UploadFile destination=#GetTempDirectory()# nameconflict=overwrite cffile action=read file=#GetTempDirectory()##cffile.serverfile# variable=myxml cfset mydoc=XmlParse(myxml) cfset scheme=#mydoc.buildingrecordset.buildingrecord.XMLAttributes.SchemeUniqu eRecordIdentifier# CFOUTPUT Name = #mydoc.buildingrecordset.buildingrecord.XMLAttributes.PersonRegistration Number# Record = #scheme# /CFOUTPUT /body /html ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:192728 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
You need a closing on line 20? -Original Message- From: Ian Vaughan [mailto:[EMAIL PROTECTED] Sent: Wednesday, 2 February 2005 6:37 PM To: CF-Talk Subject: RE: Using Coldfusion with XML I am receiving the following error when parsing an XML doc, any ideas why it is looking for p etc from the code below ? Ian -- Error Occurred While Processing Request Invalid CFML construct found on line 22 at column 1. ColdFusion was looking at the following text:plt;/ppThe CFML compiler was processing:ullt; marks the beginning of a ColdFusion tag.Did you mean LT or LTE?lia cfset tag beginning on line 20, column 2./ul The error occurred in \testpages\parse2.cfm: line 22 20 : cfset mydoc=XmlParse(myxml) 21 : 22 : cfset scheme=#mydoc.buildingrecordset.buildingrecord.XMLAttributes.SchemeUniqu eRecordIdentifier# 23 : 24 : ---CODE !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.0 Transitional//EN html head titleTEST XML/title /head body cffile action=upload filefield=UploadFile destination=#GetTempDirectory()# nameconflict=overwrite cffile action=read file=#GetTempDirectory()##cffile.serverfile# variable=myxml cfset mydoc=XmlParse(myxml) cfset scheme=#mydoc.buildingrecordset.buildingrecord.XMLAttributes.SchemeUniqu eRecordIdentifier# CFOUTPUT Name = #mydoc.buildingrecordset.buildingrecord.XMLAttributes.PersonRegistration Number# Record = #scheme# /CFOUTPUT /body /html ~| Discover CFTicket - The leading ColdFusion Help Desk and Trouble Ticket application http://www.houseoffusion.com/banners/view.cfm?bannerid=48 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:192731 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
Oh yes, thanks -Original Message- From: James Holmes [mailto:[EMAIL PROTECTED] Sent: 02 February 2005 10:58 To: CF-Talk Subject: RE: Using Coldfusion with XML You need a closing on line 20? -Original Message- From: Ian Vaughan [mailto:[EMAIL PROTECTED] Sent: Wednesday, 2 February 2005 6:37 PM To: CF-Talk Subject: RE: Using Coldfusion with XML I am receiving the following error when parsing an XML doc, any ideas why it is looking for p etc from the code below ? Ian -- Error Occurred While Processing Request Invalid CFML construct found on line 22 at column 1. ColdFusion was looking at the following text:plt;/ppThe CFML compiler was processing:ullt; marks the beginning of a ColdFusion tag.Did you mean LT or LTE?lia cfset tag beginning on line 20, column 2./ul The error occurred in \testpages\parse2.cfm: line 22 20 : cfset mydoc=XmlParse(myxml) 21 : 22 : cfset scheme=#mydoc.buildingrecordset.buildingrecord.XMLAttributes.SchemeUniqu eRecordIdentifier# 23 : 24 : ---CODE !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.0 Transitional//EN html head titleTEST XML/title /head body cffile action=upload filefield=UploadFile destination=#GetTempDirectory()# nameconflict=overwrite cffile action=read file=#GetTempDirectory()##cffile.serverfile# variable=myxml cfset mydoc=XmlParse(myxml) cfset scheme=#mydoc.buildingrecordset.buildingrecord.XMLAttributes.SchemeUniqu eRecordIdentifier# CFOUTPUT Name = #mydoc.buildingrecordset.buildingrecord.XMLAttributes.PersonRegistration Number# Record = #scheme# /CFOUTPUT /body /html ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:192733 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: Using Coldfusion with XML
Th P isn't part of the error itself, only an escaped P coming from CF's built in error handler, it does that sometimes. The most important bit is the lt; () which CF has conveniently escaped for you. Neil On Wed, 2 Feb 2005 10:37:04 -, Ian Vaughan [EMAIL PROTECTED] wrote: I am receiving the following error when parsing an XML doc, any ideas why it is looking for p etc from the code below ? Ian -- Error Occurred While Processing Request Invalid CFML construct found on line 22 at column 1. ColdFusion was looking at the following text:plt;/pp -- Neil http://www.theservicefactory.com Get Firefox - http://www.getfirefox.com ~| Discover CFTicket - The leading ColdFusion Help Desk and Trouble Ticket application http://www.houseoffusion.com/banners/view.cfm?bannerid=48 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:192738 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
Getting the following error from my ocde below, any ideas folks? --START SNIPPET--- cffile action=UPLOAD filefield=Form.UploadFile destination=Form.UploadFile nameconflict=OVERWRITE CFSET MyXML = XmlParse(#Uploadfile#) CFSET xnBuildingRecordset = MyXML.XMLRoot CFSET xnSchemeUniqueRecordIdentifier = xnBuildingRecordset.XMLAttributes[name] CFOUTPUT PThe Number is #xnSchemeUniqueRecordIdentifier#/P /CFOUTPUT -END-- Document root element is missing. Document root element is missing. The error occurred in testpages\parse.cfm: line 12 10 : cffile action=UPLOAD filefield=Form.UploadFile destination=Form.UploadFile nameconflict=OVERWRITE 11 : 12 : CFSET MyXML = XmlParse(#Uploadfile#) 13 : 14 : CFSET xnBuildingRecordset = MyXML.XMLRoot ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191910 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: Using Coldfusion with XML
Getting the following error from my ocde below, any ideas folks? What does your XML look like? Nick ~| Discover CFTicket - The leading ColdFusion Help Desk and Trouble Ticket application http://www.houseoffusion.com/banners/view.cfm?bannerid=48 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191911 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: Using Coldfusion with XML
Ian Vaughan wrote: Getting the following error from my ocde below, any ideas folks? [snip] Document root element is missing. Document root element is missing. [snip] Ian, You need to read up on the usage of CFFILE and its actions. The action upload does not load the file into a variable, it moves the file from a temporary file created by the web server during the form submission to a real file some where on the harddisk of the server. You still need to read the file in once you have uploaded it somewhere appropriate. You have been told this previously by other response to your email. Please make sure you carefully read the responses you get and read the manual for the various CF tags and function you are using. Below is some code to help you out. Regards Stephen = cffile action=upload filefield=UploadFile destination=#GetTempDirectory()# nameconflict=overwrite cffile action=read file=#GetTempDirectory()##cffile.serverfile# variable=variables.thisXMLFile CFSET variables.MyXML = XmlParse(variables.thisXMLFile) CFSET variables.xnBuildingRecordset = variables.MyXML.XMLRoot CFSET variables.xnSchemeUniqueRecordIdentifier = variables.xnBuildingRecordset.XMLAttributes[name] CFOUTPUT PThe Number is #variables.xnSchemeUniqueRecordIdentifier#/P /CFOUTPUT ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191913 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Using Coldfusion with XML
I have an XML document that needs to be converted to a fixed width Comma Seperated File so it can be inserted into the relevant databases. XSLT would perform this transformation but how can Coldfusion fit in to make this an easy to use web application. For example... The user would upload the XML file using CFFILE through a web interface. In the action page it would process the XML doc and produce the relevant CSV file. Any ideas on the best way forward on this ... TIA ~| Discover CFTicket - The leading ColdFusion Help Desk and Trouble Ticket application http://www.houseoffusion.com/banners/view.cfm?bannerid=48 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191767 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: Using Coldfusion with XML
There is a xml2query customtag which you could run then create the csv from the query, bit long winded though. On Wed, 26 Jan 2005 09:36:30 -, Ian Vaughan [EMAIL PROTECTED] wrote: I have an XML document that needs to be converted to a fixed width Comma Seperated File so it can be inserted into the relevant databases. XSLT would perform this transformation but how can Coldfusion fit in to make this an easy to use web application. For example... The user would upload the XML file using CFFILE through a web interface. In the action page it would process the XML doc and produce the relevant CSV file. Any ideas on the best way forward on this ... TIA ~| Find out how CFTicket can increase your company's customer support efficiency by 100% http://www.houseoffusion.com/banners/view.cfm?bannerid=49 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191768 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
Is it best to leave Coldfusion alone when it comes to dealing with XSLT and XML ? -Original Message- From: Ian Winter [mailto:[EMAIL PROTECTED] Sent: 26 January 2005 09:55 To: CF-Talk Subject: Re: Using Coldfusion with XML There is a xml2query customtag which you could run then create the csv from the query, bit long winded though. On Wed, 26 Jan 2005 09:36:30 -, Ian Vaughan [EMAIL PROTECTED] wrote: I have an XML document that needs to be converted to a fixed width Comma Seperated File so it can be inserted into the relevant databases. XSLT would perform this transformation but how can Coldfusion fit in to make this an easy to use web application. For example... The user would upload the XML file using CFFILE through a web interface. In the action page it would process the XML doc and produce the relevant CSV file. Any ideas on the best way forward on this ... TIA ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191771 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: Using Coldfusion with XML
Is it best to leave Coldfusion alone when it comes to dealing with XSLT and XML ? No, you can do this very neatly in CFMX using the XmlTransform() function. Also, the xml2query suggestion was a good one if you want to minimise lines of code. However, if efficiency is an issue and the XML is very simple and predictable, it may be worth writing your own lightweight parser to translate straight from XML to CSV without any intermediate steps. Nick ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191773 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: Using Coldfusion with XML
Ian Vaughan wrote: I have an XML document that needs to be converted to a fixed width Comma Seperated File so it can be inserted into the relevant databases. XSLT would perform this transformation but how can Coldfusion fit in to make this an easy to use web application. For example... The user would upload the XML file using CFFILE through a web interface. In the action page it would process the XML doc and produce the relevant CSV file. Any ideas on the best way forward on this ... What exactly is the end point? The creation of the CSV? Or does something happen with the CSV afterwards? If something is happening with the CSV afterwards, then you need to look at what you need in order to perform the next task. If the CSV is the end, then you probably don't need to involve CF other than to handle the file upload, just use the XSLT. If you want to save the generated CSV out somehow somewhere, then Nick's suggestion of the XMLTransform is probably the way to go. If you actually need to do something with the XML data in CF, but only need the CSV as a means of getting the data into CF, then xml2query will cut out the CSV middle-man giving you something easier to work with in CF. So basically, you need to think about what is next the application/data flow and process the XML accordingly. Stephen ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191774 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: Using Coldfusion with XML
So basically, you need to think about what is next the application/data flow and process the XML accordingly. These are indeed wise suggestions. I would add that you also need to evaluate your expertise, since complex XSLT programming can be tricky and require specific knowledge Massimo Foti DW tools: http://www.massimocorner.com CF tools: http://www.olimpo.ch/tmt/ ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191775 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
The end point is with the fixed with CSV file being generated and saved so that can be input into the relevant database tables. So below would be the code to select the xml doc. form action=xml.cfm ENCTYPE=multipart/form-data method=post name=form input type=file name=UploadFile p input type=submit name=submit value=Upload Document /form Then in the xml.cfm page what code would be needed to perform the transformation. Are there any CF tutorials on the www for this as it will be a different process to just simply uploading a doc to a file server ? i.e. cffile action=UPLOAD filefield=Form.UploadFile destination=downloads\documents nameconflict=OVERWRITE -Original Message- From: Massimo Foti [mailto:[EMAIL PROTECTED] Sent: 26 January 2005 10:54 To: CF-Talk Subject: Re: Using Coldfusion with XML So basically, you need to think about what is next the application/data flow and process the XML accordingly. These are indeed wise suggestions. I would add that you also need to evaluate your expertise, since complex XSLT programming can be tricky and require specific knowledge Massimo Foti DW tools: http://www.massimocorner.com CF tools: http://www.olimpo.ch/tmt/ ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191777 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: Using Coldfusion with XML
Are there any CF tutorials on the www for this as it will be a different process to just simply uploading a doc to a file server ? http://www.macromedia.com/devnet/mx/coldfusion/xml_xslt.html I would suggest to start from here: http://www.macromedia.com/devnet/mx/coldfusion/articles/xmlxslt.pdf Massimo Foti DW tools: http://www.massimocorner.com CF tools: http://www.olimpo.ch/tmt/ ~| Find out how CFTicket can increase your company's customer support efficiency by 100% http://www.houseoffusion.com/banners/view.cfm?bannerid=49 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191778 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
Are there any CF tutorials on the www for this as it will be a different process to just simply uploading a doc to a file server ? http://www.macromedia.com/devnet/mx/coldfusion/xml_xslt.html I would suggest to start from here: http://www.macromedia.com/devnet/mx/coldfusion/articles/xmlxslt.pdf In case you go that way for XML/XSL reference I always find http://zvon.org helpful More specifically http://zvon.org/xxl/XSLTutorial/Output/index.html -- dc ~| Discover CFTicket - The leading ColdFusion Help Desk and Trouble Ticket application http://www.houseoffusion.com/banners/view.cfm?bannerid=48 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191779 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
Is there really a requirement to go through csv? Why? If the point is to get the data into a db, what's the reason to pump it through a csv file on the way? (Assuming that cf has access to the db.) Am I missing part of your stated needs? Dave Merrill The end point is with the fixed with CSV file being generated and saved so that can be input into the relevant database tables. ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191794 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
Thanks for the links guys Much appreciated -Original Message- From: COLLIE David [mailto:[EMAIL PROTECTED] Sent: 26 January 2005 12:17 To: CF-Talk Subject: RE: Using Coldfusion with XML Are there any CF tutorials on the www for this as it will be a different process to just simply uploading a doc to a file server ? http://www.macromedia.com/devnet/mx/coldfusion/xml_xslt.html I would suggest to start from here: http://www.macromedia.com/devnet/mx/coldfusion/articles/xmlxslt.pdf In case you go that way for XML/XSL reference I always find http://zvon.org helpful More specifically http://zvon.org/xxl/XSLTutorial/Output/index.html -- dc ~| Discover CFTicket - The leading ColdFusion Help Desk and Trouble Ticket application http://www.houseoffusion.com/banners/view.cfm?bannerid=48 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191801 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
Dave There is no real requirement, would it be easier (coding wise) to transform the XML files straight into the database via CFFILE ? Rather than producing a CSV file? -Original Message- From: Dave Merrill [mailto:[EMAIL PROTECTED] Sent: 26 January 2005 14:12 To: CF-Talk Subject: RE: Using Coldfusion with XML Is there really a requirement to go through csv? Why? If the point is to get the data into a db, what's the reason to pump it through a csv file on the way? (Assuming that cf has access to the db.) Am I missing part of your stated needs? Dave Merrill The end point is with the fixed with CSV file being generated and saved so that can be input into the relevant database tables. ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191808 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: Using Coldfusion with XML
Ian Vaughan wrote: Dave There is no real requirement, would it be easier (coding wise) to transform the XML files straight into the database via CFFILE ? Rather than producing a CSV file? Ian, Are you trying to just dump the CSV into a column in a table in your database? Or are you looking at taking the XML root as being a table that exists in your database, the children in that xml packet being rows and columns in your table and putting each child under the root into a row in the database? Stephen ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191810 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
Yes taking the XML doc and parsing the information stored within into a database table. -Original Message- From: Stephen Moretti (cfmaster) [mailto:[EMAIL PROTECTED] Sent: 26 January 2005 15:00 To: CF-Talk Subject: Re: Using Coldfusion with XML Ian Vaughan wrote: Dave There is no real requirement, would it be easier (coding wise) to transform the XML files straight into the database via CFFILE ? Rather than producing a CSV file? Ian, Are you trying to just dump the CSV into a column in a table in your database? Or are you looking at taking the XML root as being a table that exists in your database, the children in that xml packet being rows and columns in your table and putting each child under the root into a row in the database? Stephen ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191812 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: Using Coldfusion with XML
Ian Vaughan wrote: Yes taking the XML doc and parsing the information stored within into a database table. ok - in which case - I refer you to point 3 of my previous email If you actually need to do something with the XML data in CF, but only need the CSV as a means of getting the data into CF, then xml2query will cut out the CSV middle-man giving you something easier to work with in CF. You can then use the query thats been created from the xml to insert the data into your database. Regards Stephen ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191817 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using Coldfusion with XML
Using the following code I am getting an error complaining of no destination specified for the UPLOAD, but in this case what would this be as I am not uploading the XML file to a location but to a variable to process form action=parse.cfm ENCTYPE=multipart/form-data method=post name=form input type=file name=UploadFile p input type=submit name=submit value=Upload Document /form And my action page of body cffile action=UPLOAD filefield=Form.UploadFile CFSET MyXML = XmlParse(#Uploadfile#) CFSET xnBuildingRecord = MyXML.XMLRoot CFSET xnSchemeUniqueRecordIdentifier = xnBuildingRecord.XMLAttributes[name] CFOUTPUT PThe Number is #xnSchemeUniqueRecordIdentifier#/P/CFOUTPUT /body /html -Original Message- From: Stephen Moretti (cfmaster) [mailto:[EMAIL PROTECTED] Sent: 26 January 2005 15:31 To: CF-Talk Subject: Re: Using Coldfusion with XML Ian Vaughan wrote: Yes taking the XML doc and parsing the information stored within into a database table. ok - in which case - I refer you to point 3 of my previous email If you actually need to do something with the XML data in CF, but only need the CSV as a means of getting the data into CF, then xml2query will cut out the CSV middle-man giving you something easier to work with in CF. You can then use the query thats been created from the xml to insert the data into your database. Regards Stephen ~| Find out how CFTicket can increase your company's customer support efficiency by 100% http://www.houseoffusion.com/banners/view.cfm?bannerid=49 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191820 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
RE: Using ColdFusion with XML
I don't think you can upload directly into a variable into memory. I believe the process will need to be: Upload file from client to server Read file on server into memory variable Process variable into xml -- Ian Skinner Web Programmer BloodSource www.BloodSource.org Sacramento, CA C code. C code run. Run code run. Please! - Cynthia Dunning ...-Original Message- ...From: Ian Vaughan [mailto:[EMAIL PROTECTED] ...Sent: Wednesday, January 26, 2005 7:50 AM ...To: CF-Talk ...Subject: RE: Using Coldfusion with XML ... ...Using the following code I am getting an error complaining of no ...destination specified for the UPLOAD, but in this case what would this ...be as I am not uploading the XML file to a location but to a variable to ...process ... ... ...form action=parse.cfm ENCTYPE=multipart/form-data method=post ...name=form ...input type=file name=UploadFile ...p ...input type=submit name=submit value=Upload Document .../form ... ...And my action page of ... ...body ... ...cffile action=UPLOAD filefield=Form.UploadFile ... ...CFSET MyXML = XmlParse(#Uploadfile#) ... ...CFSET xnBuildingRecord = MyXML.XMLRoot ... ...CFSET xnSchemeUniqueRecordIdentifier = ...xnBuildingRecord.XMLAttributes[name] ... ...CFOUTPUT ...PThe Number is #xnSchemeUniqueRecordIdentifier#/P/CFOUTPUT .../body .../html ... ... ... ...-Original Message- ...From: Stephen Moretti (cfmaster) [mailto:[EMAIL PROTECTED] ...Sent: 26 January 2005 15:31 ...To: CF-Talk ...Subject: Re: Using Coldfusion with XML ... ...Ian Vaughan wrote: ... ...Yes taking the XML doc and parsing the information stored within into a ... ...database table. ... ... ...ok - in which case - I refer you to point 3 of my previous email ... ...If you actually need to do something with the XML data in CF, but only ...need the CSV as a means of getting the data into CF, then xml2query ...will cut out the CSV middle-man giving you something easier to work ...with in CF. ... ...You can then use the query thats been created from the xml to insert the ...data into your database. ... ...Regards ... ...Stephen ... ... ... ... ... ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191823 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Re: Using Coldfusion with XML
You need to add a DESTINATION attribute to your CFFile tag: cffile action=UPLOAD filefield=Form.UploadFile destination=c:\someDirectory -joe -- For Tabs, Trees, and more, use the jComponents: http://clearsoftware.net/client/jComponents.cfm ~| Logware (www.logware.us): a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:191838 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations Support: http://www.houseoffusion.com/tiny.cfm/54
Coldfusion and XML
Forgive me if this is a very stupid question or in some way wrong, However, I think I need to send an XML feed back to a client from the server, the client machine is a touch screen that will remotely make a call to, I think, a file on our webserver that will run a query on the database and return the results - which I believe have to be in the form of an XML Feed. Is this possible, can someone give me some pointers? Thanks, Dave [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
RE: Coldfusion and XML
look @ cfsavecontent to create the xml. maybe look @ cfhttp to make the call to the server to get the xml generated? maybe look @ using a cfmx webservice, and have the browser on the touch screen make a request to the webservice. some ideas? tony -Original Message- From: David Ashworth [mailto:[EMAIL PROTECTED] Sent: Friday, May 07, 2004 9:27 AM To: CF-Talk Subject: Coldfusion and XML Forgive me if this is a very stupid question or in some way wrong, However, I think I need to send an XML feed back to a client from the server, the client machine is a touch screen that will remotely make a call to, I think, a file on our webserver that will run a query on the database and return the results - which I believe have to be in the form of an XML Feed. Is this possible, can someone give me some pointers? Thanks, Dave [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
Re: Coldfusion and XML
Dave I think I need to send an XML feed back to a client from the server, the client machine is a touch screen that will remotely make a call to, I think, a file on our webserver that will run a query on the database and return the results - which I believe have to be in the form of an XML Feed. Not stupid or wrong but certainly possible - the touch screen can contain a link to a ColdFusion template which generates an XML document. Nick [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
Re: Coldfusion and XML
On Friday 07 May 2004 14:37 pm, Tony Weeg wrote: look @ cfsavecontent to create the xml. Why not use the proper XML types and functions CF gives you ? -- Tom Chiverton Advanced ColdFusion Programmer Tel: +44(0)1749 834997 email: [EMAIL PROTECTED] BlueFinger Limited Underwood Business Park Wookey Hole Road, WELLS. BA5 1AF Tel: +44 (0)1749 834900 Fax: +44 (0)1749 834901 web: www.bluefinger.com Company Reg No: 4209395 Registered Office: 2 Temple Back East, Temple Quay, BRISTOL. BS1 6EG. *** This E-mail contains confidential information for the addressee only. If you are not the intended recipient, please notify us immediately. You should not use, disclose, distribute or copy this communication if received in error. No binding contract will result from this e-mail until such time as a written document is signed on behalf of the company. BlueFinger Limited cannot accept responsibility for the completeness or accuracy of this message as it has been transmitted over public networks.*** [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
RE: Coldfusion and XML
Thanks for the tips so far Can this be done using CF5 as opposed to MX? Thanks, Dave -Original Message- From: Thomas Chiverton [mailto:[EMAIL PROTECTED] Sent: 07 May 2004 15:55 To: CF-Talk Subject: Re: Coldfusion and XML On Friday 07 May 2004 14:37 pm, Tony Weeg wrote: look @ cfsavecontent to create the xml. Why not use the proper XML types and functions CF gives you ? -- Tom Chiverton Advanced ColdFusion Programmer Tel: +44(0)1749 834997 email: [EMAIL PROTECTED] BlueFinger Limited Underwood Business Park Wookey Hole Road, WELLS. BA5 1AF Tel: +44 (0)1749 834900 Fax: +44 (0)1749 834901 web: www.bluefinger.com Company Reg No: 4209395 Registered Office: 2 Temple Back East, Temple Quay, BRISTOL. BS1 6EG. *** This E-mail contains confidential information for the addressee only. If you are not the intended recipient, please notify us immediately. You should not use, disclose, distribute or copy this communication if received in error. No binding contract will result from this e-mail until such time as a written document is signed on behalf of the company. BlueFinger Limited cannot accept responsibility for the completeness or accuracy of this message as it has been transmitted over public networks.*** _ [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
RE: Coldfusion and XML
Can this be done using CF5 as opposed to MX? You can generate XML with CF 5 by either generating raw text that happens to be well-formed XML, or by using a third-party XML parser to generate XML for you. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ phone: 202-797-5496 fax: 202-797-5444 [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
ColdFusion and XML
I generated a cfm page that process a xml document that is submitted in a form. The problem is the XML document is encoded and it causes my cfm page to error out. Does anyone know how to decode an encoded xml page? Here is the xml I am receiving ?xml version=1.0 encoding=ISO-8859-1? upload table=INVOICE franid=000 password=8 record FranID000/FranID InvoiceID18647/InvoiceID CustomerID12952/CustomerID NumGarments0/NumGarments DryCleaning0/DryCleaning Laundry0/Laundry Alterations3/Alterations ShoeRepair0/ShoeRepair Other0/Other DescrOther/DescrOther Surcharge0/Surcharge Discount0/Discount TotalSale3/TotalSale Tax0/Tax Total3/Total /record /upload [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
Re: ColdFusion and XML
What kind of encoding? Do you mean that the XML document you posted is the value of a form element, a textarea for instance, and you'd like to access the data in the XML document? -- Howard Fore, Web Developer, Professional Career Development Institute [EMAIL PROTECTED], 770-729-8400, x5258 On Apr 16, 2004, at 7:42 AM, chad wrote: I generated a cfm page that process a xml document that is submitted in a form. The problem is the XML document is encoded and it causes my cfm page to error out. Does anyone know how to decode an encoded xml page? [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
Re: ColdFusion and XML
I am not sure what type of encoding. The Xml I get has this. ?xml version=1.0 encoding=ISO-8859-1? - Original Message - From: Howard Fore To: CF-Talk Sent: Friday, April 16, 2004 8:11 AM Subject: Re: ColdFusion and XML What kind of encoding? Do you mean that the XML document you posted is the value of a form element, a textarea for instance, and you'd like to access the data in the XML document? -- Howard Fore, Web Developer, Professional Career Development Institute [EMAIL PROTECTED], 770-729-8400, x5258 On Apr 16, 2004, at 7:42 AM, chad wrote: I generated a cfm page that process a xml document that is submitted in a form. The problem is the XML document is encoded and it causes my cfm page to error out. Does anyone know how to decode an encoded xml page? [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
RE: ColdFusion and XML
if you are passing this in a form var, ala input type=hidden name=myXML value=?xml version=1.0 encoding=IS.blah blah this is going to bomb.Have to mind your ticks and quotes.For quick approach that may get you by, us value='?xml version=1.0 encoding=IS.blah blahOrvalue=?xml version='1.0' encoding='IS.blah blah Doug -Original Message- From: chad [mailto:[EMAIL PROTECTED] Sent: Friday, April 16, 2004 8:52 AM To: CF-Talk Subject: Re: ColdFusion and XML I am not sure what type of encoding. The Xml I get has this. ?xml version=1.0 encoding=ISO-8859-1? - Original Message - From: Howard Fore To: CF-Talk Sent: Friday, April 16, 2004 8:11 AM Subject: Re: ColdFusion and XML What kind of encoding? Do you mean that the XML document you posted is the value of a form element, a textarea for instance, and you'd like to access the data in the XML document? -- Howard Fore, Web Developer, Professional Career Development Institute [EMAIL PROTECTED], 770-729-8400, x5258 On Apr 16, 2004, at 7:42 AM, chad wrote: I generated a cfm page that process a xml document that is submitted in a form. The problem is the XML document is encoded and it causes my cfm page to error out. Does anyone know how to decode an encoded xml page? _ [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
RE: ColdFusion and XML
I generated a cfm page that process a xml document that is submitted in a form. The problem is the XML document is encoded and it causes my cfm page to error out. Does anyone know how to decode an encoded xml page? By default, when you submit an HTML form with METHOD=POST, the data sent to the server is URL-encoded. Basically, any characters not allowed in a URL are escaped with their corresponding escape sequences. Spaces, for example, are replaced with plus signs or %20. Normally, the server can easily decode that, so you don't have to worry about it. XML contains lots of stuff you can't put in a URL, and I imagine CF is simply getting confused about how to decode it. There's an IE-specific character encoding issue described here: http://www.biglist.com/lists/xsl-list/archives/200305/msg01144.html You do have some options, though. One option would be to use the GetHTTPRequestData function to return a structure containing the various parts of the HTTP request, and go through the content key and manually decode characters as appropriate. Another option might be to specify ENCTYPE=text/xml instead of using the default ENCTYPE=application/x-www-urlencoded within your HTML form tag. I will note that I don't know how well either of these options would work, but that's where I'd start if I were you. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ phone: 202-797-5496 fax: 202-797-5444 [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
ColdFusion and XML
I generated a cfm page that process a xml document that is submitted in a form. The problem is the XML document is encoded and it causes my cfm page to error out. Does anyone know how to decode an encoded xml page? [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
RE: ColdFusion and XML
How did you encode the XML? Paul Kenney [EMAIL PROTECTED] 916-212-4359 -Original Message- From: chad [mailto:[EMAIL PROTECTED] Sent: Thursday, April 15, 2004 6:33 AM To: CF-Talk Subject: ColdFusion and XML I generated a cfm page that process a xml document that is submitted in a form. The problem is the XML document is encoded and it causes my cfm page to error out. Does anyone know how to decode an encoded xml page? [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
Re: ColdFusion and XML
This is the xml I am receiving. This xml is not generated by me. It is being sent to me via a form. My cfm page handles the xml that comes in. ?xml version=1.0 encoding=ISO-8859-1? upload table=INVOICE franid=000 password=8 record FranID000/FranID InvoiceID18647/InvoiceID CustomerID12952/CustomerID NumGarments0/NumGarments DryCleaning0/DryCleaning Laundry0/Laundry Alterations3/Alterations ShoeRepair0/ShoeRepair Other0/Other DescrOther/DescrOther Surcharge0/Surcharge Discount0/Discount TotalSale3/TotalSale Tax0/Tax Total3/Total /record /upload - Original Message - From: Paul Kenney To: CF-Talk Sent: Thursday, April 15, 2004 1:06 PM Subject: RE: ColdFusion and XML How did you encode the XML? Paul Kenney [EMAIL PROTECTED] 916-212-4359 -Original Message- From: chad [mailto:[EMAIL PROTECTED] Sent: Thursday, April 15, 2004 6:33 AM To: CF-Talk Subject: ColdFusion and XML I generated a cfm page that process a xml document that is submitted in a form. The problem is the XML document is encoded and it causes my cfm page to error out. Does anyone know how to decode an encoded xml page? [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]