"Brian K. Buckley" <[EMAIL PROTECTED]> wrote:
> Is there a good way to capture the output from a snippet of jsp into a
> String variable that can be reused multiple times in a page?
>
> - Brian
>
> As a simple example, if one needed to have the line:
>
> <tr><th align='left' >Name</th><td align='right' ><html:text
> property='name'/></td></tr>
>
> appear in several places, how can one set a String namerow so that the line
> can be redisplayed by saying <%=namerow%> instead of repeating the whole
> snippet? Note that the snippet includes a custom tag.
Not really. The only way I know, is to enclose the snippet into a method
with a variable called "out". HTML in JSP will be translated into
out.print("....");
--
gR