How to add a new attribute via xsl in an existing xml structure
Joined: Jul 31, 2011
Problem : I need to add a new variable DateTime(Integer type) in the current hierarchy(of dbPublish.xml) as a event attribute. For example,
I have added the code in red in dbPublish.xsl, which will give me DateTime=”20110802124026”
Now, where should I call my event template so as to put my attribute at the desired location.
Please provide your valuable inputs.
Joined: Jan 18, 2011
If you mean the xml document itself does not actually have DateTime attribute on its "event" element, you can do it like this, modifying the attribute template and adding one named template "DateTime" below.
You can thereby take out the template for event, and named template "FormatDate" and "FormatTime".