Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


RE: [xsl] XSL questions

From: cknell@----------
To:
Date: 6/1/2006 4:08:00 PM
1) how to embed html tags in a XML which will be processed by XSL?

Just type them in. Keep in mind that HTML tags, when embedded in an XML document, must meet the well-formedness test. For example you can't have this:

<ol>
  <li>banana
  <li>apple
  <li>grape
</ol>

in an XML document. You must close the tags like this:
<ol>
  <li>banana</li>
  <li>apple</li>
  <li>grape</li>
</ol>

All HTML attributes must be quoted:

<td width=0> ---> NOT LEGAL IN XML
<td width="0"> --> OK


2) Counter inside of xsl:for-each

No. Can't be done. Variables cannot change value once assigned. You will have to think of another way to do this that is in keeping with the "no-side-effects", declarative nature of XSLT.

3) Flag inside of xsl:for-each

See the answer to 2) above. 

xsl:for-each is not a looping construct. Its name resembles a common looping construct in procedural languages, but it's purpose in XSLT is different.
===========================================

This list works best when you tell us what you want to accomplish and show a sample of the input and desired output.
-- 
Charles Knell
cknell@xxxxxxxxxx - email


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent