Subject: RE: [xsl] JSP includes in XSLT From: David Nelson <David.Nelson@xxxxxxxxxxxxxx> Date: Thu, 11 Jul 2002 14:07:16 -0500 |
I usually just lurk to try to learn a bit from you guys but I have a bit experience with jsp includes and below is something you could use. <jsp:include page="{relativeURL | %= expression %}" [ flush="true | false" ] /> Note that this behaves a bit differently than an include directive. An include Action really behaves somewhat like a bean. This really just depends on its design though. Maybe peruse the documentation to see how this would fit in your design. HTH Dave --> -----Original Message----- --> From: sara.mitchell@xxxxxxxxx [mailto:sara.mitchell@xxxxxxxxx] --> Sent: Thursday, July 11, 2002 1:45 PM --> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx --> Subject: RE: [xsl] JSP includes in XSLT --> --> --> The only way to do it is to use d-o-e (disable-output-escaping). --> I've done this in some of my own stylesheets for very --> similar reasons. --> If the URLs to the file attributes are known (i.e., not --> dynamic), it's fairly simple. Something like this: --> --> <xsl:template match="x"> --> <html> --> <head> --> <title><xsl:value-of select="title"></title> --> <xsl:text disable-output-escaping="yes"><![CDATA[<%@ include --> file="help_fd_table_end.inc"]]></xsl:text> --> </head> --> ... --> </xsl:template> --> --> The CDATA sections are required and you may also need to --> be careful --> about line ends and other white space. If parts of the --> file name are --> dynamic and have to be derived from content in your input --> XML, you're --> going to have to flip back and forth inbetween <xsl:text> --> with d-o-e set --> and the usual XSLT instructions. --> --> It would be nice if JSP had an XML compatible syntax for this, --> wouldn't it? --> --> Sara Mitchell --> --> > -----Original Message----- --> > From: Brad Miller [mailto:Brad.Miller@xxxxxxxxxxx] --> > Sent: Thursday, July 11, 2002 9:26 AM --> > To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx --> > Subject: [xsl] JSP includes in XSLT --> > --> > --> > I am outputting jsp's with my stylesheet and I need to have a --> > few includes throught the jsp. --> > the include looks like this --> > <%@include file="help_fd_table_end.inc" %> --> > It seems to be hanging on the % sign. --> > --> > 90% of my output is HTML the other 10% is inludes like this one. --> > So I just need to add the includes in the stylesheet like I --> > would any other HTML tag. --> > --> > Anyone know how to get around this? --> > --> > --> > --> > Thanks --> > Brad --> > --> > XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list > XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] JSP includes in XSLT, sara . mitchell | Thread | RE: [xsl] JSP includes in XSLT, Brad Miller |
RE: [xsl] JSP includes in XSLT, sara . mitchell | Date | RE: [xsl] JSP includes in XSLT, Brad Miller |
Month |