I have an xml file in which there is tag namely, <Gender/> It carries either 'M' or 'F' as data, now my work is to test the value and write <Gender_Tag>Male</Gender_Tag>
or <Gender_Tag>Female</Gender_Tag>
according to the values M or F respectively .. I tried this code .. It used to work in other circumstances..
<xsl:template match="root/details/Gender">
<xsl:if test="Gender='M'">
<Gender_Tag>
<xsl:text>Male</xsl:text>
</Gender_Tag>
</xsl:if>
<xsl:if test="Gender='F'">
<Gender_Tag>
<xsl:text>Female</xsl:text>
</Gender_Tag>
</xsl:if>
</xsl:template>
And here is my XML input ..
<root>
<details>
<Gender>M</Gender>
<nickname/>
<Alias>123aaaaaaaaa</Alias>
<AlternatePhone>54654231aaaaa</AlternatePhone>
<Fname>abc</Fname>
<Lname>xyz</Lname>
<PhoneNumber>345313213</PhoneNumber>
<BirthDate/>
</details>
</root>
Thank you every one, who all answered .. It was a bug which was troubling me .. :)
Code is working properly ... thank you "stackoverflow" :-)