Hi, anyone knows if is possible to save xml by using the new dataeditor in the usercontrol wrapper in Umbraco 4.6. Or where could I get a tutorial about it.
Yes, it's now possible to store XML with the UserControlWrapper in 4.6. According to Tim's comments on this thread you just save the XML as a string or an XmlDocument and the wrapper will detect this and save as XML. I've already tested by returning a string and it works great!
Save XML usercontrol wrapper, umbraco 4.6
Hi, anyone knows if is possible to save xml by using the new dataeditor in the usercontrol wrapper in Umbraco 4.6. Or where could I get a tutorial about it.
Thanks.
Hi Byron,
Yes, it's now possible to store XML with the UserControlWrapper in 4.6. According to Tim's comments on this thread you just save the XML as a string or an XmlDocument and the wrapper will detect this and save as XML. I've already tested by returning a string and it works great!
-Tom
Hi Tom, thanks for this. Are you using XDocument .Net class for this? Do you have some code as example please. I appreciate the help.
Byron
Hi Byron,
No, I'm just saving a string formatted as XML and Umbraco handles the rest.
txtXml just has a regular XML string, such as:
...and it just works! Let me know if you can't get it going...
-Tom
I was just about to post what I did, when I saw your response, This is what I did and yes it does work!
return xDoc.ToString();
}
But I can get it to save CDATA content. This is what it produces
Any ideas?
Thanks
Byron
is working on a reply...