im stuck at this point:
XML source
<config>
<username>user</username>
<password>pass</password>
<link>1.2.3.4</link>
<port>99</port>
</config>
XML target
<some wrapping="tag"> <!-- is fixed and should be just inserted -->
<property name="username" value="user"/>
<property name="password" value="pass"/>
<!-- link and port are merged into one attribute -->
<property name="URL" value="1.2.3.4:99" />
</some>
XSLT i have so far
<xsl:template match="config">
<some wrapping="tag">
<xsl:apply-templates />
</some>
<xsl:template>
<xsl:template match="config/username | config/password">
<property name="{local-name()}">
<xsl:attribute name="value">
<xsl:value-of select="." />
</xsl:attribute>
</property>
</xsl:template>
<xsl:template match="@*|node()">
<xsl:copy>
<xsl:apply-templates select="@*|node()"/>
</xsl:copy>
</xsl:template>
It gives me desired result until it comes to the point of merging link and port nodes into URL property with value of port and link.
Thanks in advance!