tiles-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Antonio <antonio.petre...@gmail.com>
Subject Re: How to make Java variables accessible across Tiles attribute
Date Mon, 27 Oct 2008 07:38:58 GMT
2008/10/25 Steven Lee <steven987@comcast.net>:
> <tiles:putAttribute name="head" type="string">
> <%
>   String tmp = "JSP Test";
> %>
> </tiles:putAttribute>
>
> <tiles:putAttribute name="content" type="string">
> <p><%= tmp %></p>
> </tiles:putAttribute>

The "tmp" variable is visible only inside the first
<tiles:putAttribute> tag. This is a JSP specification. Simply specify
the "tmp" variable in a place that is visible to both tags.

Antonio

Mime
View raw message