OK, any help here would be appreciated,.

here goes.. I have a simple XML file thus  :

<?xml version="1.0" encoding="iso-8859-1"?>
<LANGUAGES>
        <ENGLISH>
                <BODYTEXT>
                                <VALUE>THIS IS ENGLISH</VALUE>

                </BODYTEXT>
        </ENGLISH>
</LANGUAGES>

I can read this into a page no probs using : 

<cfset sCurrentDirectory = GetDirectoryFromPath(CGI.Path_Translated)>

<cf_SOXML 
  action="XML2CF"
  input="#sCurrentDirectory#example.xml"
  output="stTemplateContent"
  type="file">

 <cfdump var="#stTemplateContent#"> 

When I try to copy it back into a file I get errors in that it will add a
root element even when I already have one (either by expicitly adding the
roorelement or not).

I am using the following code to save :

<cf_SOXML
  action="CF2XML"
  input="#stTemplateContent#"
  output="xmlOutput"  
  encoding="iso-8859-1">

<cffile action="WRITE" file="#sCurrentDirectory#example.xml"
output="#xmlOutput#"> 

I am using CF5 at the mo, but it will be on CF4x
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Signup for the Fusion Authority news alert and keep up with the latest news in 
ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm

Reply via email to