~ubuntu-branches/ubuntu/trusty/libstruts1.2-java/trusty-proposed

« back to all changes in this revision

Viewing changes to web/tiles-documentation/test/testStrutsAction.jsp

  • Committer: Bazaar Package Importer
  • Author(s): Arnaud Vandyck
  • Date: 2004-11-19 15:35:25 UTC
  • Revision ID: james.westby@ubuntu.com-20041119153525-mdu08a76z4zo67xt
Tags: upstream-1.2.4
ImportĀ upstreamĀ versionĀ 1.2.4

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<%@ taglib uri="/WEB-INF/struts-tiles.tld" prefix="tiles" %>
 
2
 
 
3
<%-- Test tiles and struts action integration (require factory) 
 
4
--%>
 
5
<hr>
 
6
<strong>Test definition set in action, and action forward to another definition</strong>
 
7
<br>
 
8
<tiles:insert page="/test/testAction.do" >
 
9
  <tiles:put name="title"       value="Test definition set in action, and action forward to another definition. Title is overloaded from insert" />
 
10
    <%-- header and body values come from definition used in action's forward --%>
 
11
    <%-- name of definition to use in action --%>
 
12
  <tiles:put name="set-definition"   value="test.layout.test1" />
 
13
</tiles:insert>
 
14
 
 
15
<hr>
 
16
<strong>Test overload parameter in action</strong>
 
17
<br>
 
18
<tiles:insert page="/test/testAction.do" >
 
19
  <tiles:put name="title"                 value="Test overload parameter in action" />
 
20
  <tiles:put name="header"                value="header.jsp" />
 
21
  <tiles:put name="body"                  value="body.jsp" />
 
22
    <%-- name and value of attribute to set in action --%>
 
23
  <tiles:put name="set-attribute"         value="title" />
 
24
  <tiles:put name="set-attribute-value"   value="Test overload parameter in action : Overloaded title" />
 
25
</tiles:insert>
 
26
 
 
27
<hr>
 
28
<strong>Test definition set in action, and action forward directly to jsp</strong>
 
29
<br>
 
30
<tiles:insert page="/test/testActionForwardJsp.do" >
 
31
  <tiles:put name="title"            value="Test definition set in action, and action forward directly to jsp" />
 
32
  <tiles:put name="header"           value="header.jsp" />
 
33
  <tiles:put name="body"             value="body.jsp" />
 
34
</tiles:insert>
 
35
 
 
36