Question:

How can I include conditional statements in XML?

Answer:

We cannot include conditional statement as like programming language.

<foo if{DB}="A">bar</foo>

This can be done by using Document Type Definition(DTD).

<xsl:if test="@foo=’bar’">
 
<xsl:text>Hello, world!</xsl:text>
 
</xsl:if>

 


Keywords:

© 2017 QuizBucket.org