you can use the "@" symbol to test the attribut,
<xsl:template match="node1">
    <xsl:if test="@attr1">  /*test whether has the attribute attr1 or not*/
       /*do your operation at here*/
----- Original Message -----
Sent: Monday, June 24, 2002 1:23 PM
Subject: some help..

Hi all,
I have a XML file like this..
    <node1 attr1="efhg" attr2="efhef"/>
    <node2 attr2="erfje" attr3="efjef"/>
Is there any method/function in XSL to check whether
any of the attributes in the node exists..

Vinod Nayak i-flex solutions ltd. Voice: (91)-228 43 00, x 6501
Fax:   (91)-22-843 13

---------------------------------------------------------------------------- This message contains privileged and confidential information and is intended only for the individual named.If you are not the intended recipient you should not disseminate,distribute,store,print, copy or deliver this message.Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system.E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted,corrupted,lost,destroyed,arrive late or incomplete or contain viruses.The sender therefore does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required please request a hard-copy version. ----------------------------------------------------------------------------

Reply via email to