I put //div[(_at_)class='section'][popsition()=1]//h2 in XPath and it is
gives the first h2 section.
<!-- manage h2 elements -->
You need to decide whether your input is or is not in the XHTML
namespace, it is very inconvenient in XSLT to handle both at the same
time. If the first version works, then h2 is not in the xhtml namespace
in your source file and in that case the second one won't
match. Conversely if the second one works then your source file does use
the XHTML namespace (assuming that is what xhtml: is bound to) and in
that case the first expression should not match anything.
If you use a select attribute value-of should be empty, that isn't empty
it contains a newline.
Sorry I couldn't understand the rest of your problem statement.
If your XSLT engine is adding xmlns="" to your output it is usually a
sign that you are generating some elements in a namespace and some not.
this is usually a bad idea. As for the input document you should decide
whether you are generating xhtml in which case everything should be in
the xhtml namespace, or html, in which case everything should be in no
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list