[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: XSL Help!!
Chandra - wrote: Hi there, I have a couple of questions on XSL stylesheets. 1)<xsl:template match="MEMBER"> <xsl:apply-templates select="NAME"/> <xsl:apply-templates select="Phone[@type='work']"/> </xsl:template> yes Also will the NAME template rule be applied to each one of the NAME nodes before the Phone node is selected? yes, and in that order you gave here, first all names then all phones. With <xsl:apply-templates select="(NAME|Phone[@type='work'])"/> it they would appear instead in document order, which could be Name-Phone-Name-Phone etc. 2) <xsl:variable name='signers' select=/legal_authenticator/person'/> <xsl:if test='$signers'> ..... ..... </xsl:if> yes, actually there are some pretty wild (but useful) rules by which values are cast into the boolean type to make the test. But and a non-existing node is false. 3)<person_name> <nm> <GIV V="Henry"/> <FAM V="Levin"/> </nm> <person_name.type_cd V="L" S="2d"/> </person_name> Hehe, I know this stuff you're doing. This is HL7 CDA schema or something close of quite an outdated interim release, isn't it? Funny how small the world is :-) Well, this is a pretty basic XSLT question and you should want to study XSLT in more detail (it's the coolest language there is.) But since you seem to have to read XSLT from someone else and since you are an HL7 fellow, here's the answer: person_name[...] makes a condition on the person_name node, i.e., the result is the person_name(s) if it exists AND if the condition term in the brackets is true. This schema has changed a lot since then, you may want to update to the more current specifications :-) regards -Gunther -- Gunther Schadow, M.D., Ph.D. gschadow@xxxxxxxxxxxxxxx Medical Information Scientist Regenstrief Institute for Health Care Adjunct Assistant Professor Indiana University School of Medicine tel:1(317)630-7960 http://aurora.regenstrief.org XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|