|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: href problem...using CDATA needed?
At 04:24 PM 6/13/2003, TomP wrote:
In your template, it seems very unusual to have an apply-templates instruction within the body of an anchor element. An anchor is supposed to contain only inline elements - it is not clear why you would need apply-templates. If it is going to return structured information, an anchor element is the wrong place for it. If it is going to return a bit of text like a label, chances are you can do it with just xsl:value-of. I disagree with Tom here. I prefer to use xsl:apply-templates by default all the way down, and only go to xsl:value-of (or something else) as the motivated exception. This may because I deal a lot with messy documentary data that often includes lots of mixed content, including even mixed content in the midst of anchor tags and such like (they do happen). The graceful way XSLT's so-called "push" model deals with mixed content is among its greatest misunderstood and discounted strengths. (But then mixed content itself seems to be a deep mystery to some.) There can also be stuff like images in there. In fact, with newbies I like to slap their hands for using value-of without thinking about why. :-> (This is not to say that I don't trust Tom to do the right thing for his situation: I do.) Cheers, Wendell
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
|

Cart








