XML to CSV transformation
I have made the following code to test some output from my XML. I have to convert XML to .csv .
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="text"/>
<xsl:template match="/">
<xsl:value-of select="NessusClientData_v2/Report/ReportItem/@pluginID"/>
<xsl:if test="position() != last()">
<text>,</text>
</xsl:if>
</xsl:template>
</xsl:stylesheet>
Please, can anyone tell what he/she believes that this code will do?? I want to take the "pluginID" attribute from all the "ReportItem" elements and put them to the .csv .
If anyone has any suggestions I would be gratefull since I am a nube with this stuff...
Thank you in advance.
|