This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Newbie question on XSL and lists


David Carlisle wrote:
> > Beginner rule #1 *NEVER* use xsl:for-each
> 
> why not ?

To paraphrase what Chris said, to break procedural programmers of their
bad habits. Even though this is not what it does, it is easy for beginners
to think of xsl:for-each as a way of circumventing XSLT's template
processing model, which isn't obvious to someone who just knows some
JavaScript and has seen a few XSLT code samples. Speaking from experience,
here... "ah, a friendly loop control mechanism.. now I know how to get at
those 'tags' in my document. screw this esoteric node tree,
apply-templates, template match patterns, import precedence,
built-in-templates stuff" :)

   - Mike
____________________________________________________________________
Mike J. Brown, software engineer at         My XML/XSL resources:
webb.net in Denver, Colorado, USA           http://www.skew.org/xml/


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]