struts-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lukaszlen...@apache.org
Subject [07/10] Moves showcase related JSPs under WEB-INF
Date Sun, 02 Mar 2014 21:17:45 GMT
http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/conversion/showOperations.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/conversion/showOperations.jsp b/apps/showcase/src/main/webapp/WEB-INF/conversion/showOperations.jsp
new file mode 100644
index 0000000..4cb6679
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/conversion/showOperations.jsp
@@ -0,0 +1,21 @@
+<%@taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+	<title>Struts2 Showcase - Conversion - Tiger 5 Enum</title>
+</head>
+<body>
+<div class="page-header">
+	<h1>Conversion - Tiger 5 Enum</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span12">
+			<s:iterator value="%{selectedOperations}" status="stat">
+				<s:property value="%{top.name()}" /><br/>
+			</s:iterator>
+		</div>
+	</div>
+</div>
+</body>
+</html>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/conversion/showPersonInfo.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/conversion/showPersonInfo.jsp b/apps/showcase/src/main/webapp/WEB-INF/conversion/showPersonInfo.jsp
new file mode 100644
index 0000000..24f9760
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/conversion/showPersonInfo.jsp
@@ -0,0 +1,24 @@
+<%@taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+	<title>Struts2 Showcase - Conversion - Populate Object into Struts' action List</title>
+</head>
+<body>
+<div class="page-header">
+	<h1>Conversion - Populate Object into Struts' action List</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span12">
+
+			<s:iterator value="persons" status="status">
+                 <s:label label="%{'SET '+#status.index+' Name'}" value="%{name}" /><br/>
+                 <s:label label="%{'SET '+#status.index+' Age'}" value="%{age}" /><br/>
+			</s:iterator>
+		</div>
+	</div>
+</div>
+</body>
+</html>
+

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/customTemplateDir/customTheme/ftlCustomTemplate.ftl
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/customTemplateDir/customTheme/ftlCustomTemplate.ftl b/apps/showcase/src/main/webapp/WEB-INF/customTemplateDir/customTheme/ftlCustomTemplate.ftl
new file mode 100644
index 0000000..4152334
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/customTemplateDir/customTheme/ftlCustomTemplate.ftl
@@ -0,0 +1,7 @@
+<div style="background-color:yellow;">
+<p>
+Freemarker Custom Template -
+parameter 'paramName' - ${parameters.paramName}
+</p>
+</div>
+

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/customTemplateDir/customTheme/jspCustomTemplate.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/customTemplateDir/customTheme/jspCustomTemplate.jsp b/apps/showcase/src/main/webapp/WEB-INF/customTemplateDir/customTheme/jspCustomTemplate.jsp
new file mode 100644
index 0000000..311c329
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/customTemplateDir/customTheme/jspCustomTemplate.jsp
@@ -0,0 +1,8 @@
+<%@taglib prefix="s" uri="/struts-tags" %>
+
+<div style="background-color:yellow;">
+<p>
+JSP Custom Template - 
+parameter 'paramName' - <s:property value="%{top.parameters.paramName}" />
+</p>
+</div>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/date.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/date.jsp b/apps/showcase/src/main/webapp/WEB-INF/date.jsp
new file mode 100644
index 0000000..400cd6d
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/date.jsp
@@ -0,0 +1,2 @@
+<%@ taglib prefix="s" uri="/struts-tags" %>
+<s:date name="now"/>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/empmanager/editEmployee.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/empmanager/editEmployee.jsp b/apps/showcase/src/main/webapp/WEB-INF/empmanager/editEmployee.jsp
new file mode 100644
index 0000000..aff2c3e
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/empmanager/editEmployee.jsp
@@ -0,0 +1,56 @@
+<%@ taglib prefix="s" uri="/struts-tags" %>
+<%@ taglib prefix="sx" uri="/struts-dojo-tags" %>
+<html>
+<head>
+	<s:if test="currentEmployee!=null">
+		<s:text var="title" name="item.edit"><s:param><s:text name="employee"/></s:param></s:text>
+	</s:if>
+	<s:else>
+		<s:text var="title" name="item.create"><s:param><s:text name="employee"/></s:param></s:text>
+	</s:else>
+	<title>Struts2 Showcase - CRUD Example - <s:property value="#title"/></title>
+	<s:head/>
+	<sx:head/>
+</head>
+<body>
+<div class="page-header">
+	<h1><s:property value="#title"/></h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span3">
+			<ul class="nav nav-tabs nav-stacked">
+				<li><s:url var="url" namespace="/employee" action="list"/><s:a href="%{url}">List available Employees</s:a></li>
+				<li class="active"><s:url var="url" namespace="/employee" action="edit"/><s:a href="%{url}">Create/Edit Employee</s:a></li>
+				<li><s:url var="url" namespace="/skill" action="list"/><s:a href="%{url}">List available Skills</s:a></li>
+				<li><s:url var="url" namespace="/skill" action="edit"/><s:a href="%{url}">Create/Edit Skill</s:a></li>
+			</ul>
+		</div>
+		<div class="span9">
+
+			<s:action var="skillAction" namespace="/skill" name="list"/>
+
+			<s:form name="editForm" action="save">
+				<s:textfield label="Employee Id" name="currentEmployee.empId"/>
+				<s:textfield label="%{getText('employee.firstName')}" name="currentEmployee.firstName"/>
+				<s:textfield label="%{getText('employee.lastName')}" name="currentEmployee.lastName"/>
+				<sx:datetimepicker label="Birthdate" name="currentEmployee.birthDate"/>
+				<s:textfield label="Salary" name="currentEmployee.salary" value="%{getText('format.number',{currentEmployee.salary})}" />
+				<s:checkbox fieldValue="true" label="Married" name="currentEmployee.married"/>
+				<s:combobox list="availablePositions" label="Position" name="currentEmployee.position"/>
+				<s:select list="#skillAction.availableItems" listKey="name" label="Main Skill"
+				          name="currentEmployee.mainSkill.name"/>
+				<s:select list="#skillAction.availableItems" listKey="name" listValue="description" label="Other Skills"
+				          name="selectedSkills" multiple="true"/>
+				<s:password label="Password" name="currentEmployee.password"/>
+				<s:radio list="availableLevels" name="currentEmployee.level"/>
+				<s:textarea label="Comment" name="currentEmployee.comment" cols="50" rows="3"/>
+				<s:submit value="%{getText('save')}"  cssClass="btn btn-primary"/>
+			</s:form>
+
+		</div>
+	</div>
+</div>
+</body>
+</html>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/empmanager/editSkill.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/empmanager/editSkill.jsp b/apps/showcase/src/main/webapp/WEB-INF/empmanager/editSkill.jsp
new file mode 100644
index 0000000..f47390e
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/empmanager/editSkill.jsp
@@ -0,0 +1,42 @@
+<%@taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+	<s:if test="currentSkill!=null">
+		<s:set name="submitType" value="'update'"/>
+		<s:text id="title" name="item.edit"><s:param><s:text name="skill"/></s:param></s:text>
+	</s:if>
+	<s:else>
+		<s:set name="submitType" value="'create'"/>
+		<s:text var="title" name="item.create"><s:param><s:text name="skill"/></s:param></s:text>
+	</s:else>
+	<title>Struts2 Showcase - CRUD Example - <s:property value="#title"/></title>
+</head>
+<body>
+<div class="page-header">
+	<h1><s:property value="#title"/></h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span3">
+			<ul class="nav nav-tabs nav-stacked">
+				<li><s:url var="url" namespace="/employee" action="list"/><s:a href="%{url}">List available Employees</s:a></li>
+				<li><s:url var="url" namespace="/employee" action="edit"/><s:a href="%{url}">Create/Edit Employee</s:a></li>
+				<li><s:url var="url" namespace="/skill" action="list"/><s:a href="%{url}">List available Skills</s:a></li>
+				<li class="active"><s:url var="url" namespace="/skill" action="edit"/><s:a href="%{url}">Create/Edit Skill</s:a></li>
+			</ul>
+		</div>
+		<div class="span9">
+
+			<s:form action="save">
+				<s:textfield label="%{getText('skill.name')}" name="currentSkill.name"/>
+				<s:textfield label="%{getText('skill.description')}" name="currentSkill.description"/>
+				<%--s:submit name="%{#submitType}" value="%{getText('save')}" /--%>
+				<s:submit value="%{getText('save')}" cssClass="btn btn-primary"/>
+			</s:form>
+
+		</div>
+	</div>
+</div>
+</body>
+</html>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/empmanager/index.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/empmanager/index.jsp b/apps/showcase/src/main/webapp/WEB-INF/empmanager/index.jsp
new file mode 100644
index 0000000..0da9091
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/empmanager/index.jsp
@@ -0,0 +1 @@
+<% response.sendRedirect("../employee/list.action"); %>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/empmanager/listEmployees.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/empmanager/listEmployees.jsp b/apps/showcase/src/main/webapp/WEB-INF/empmanager/listEmployees.jsp
new file mode 100644
index 0000000..1991924
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/empmanager/listEmployees.jsp
@@ -0,0 +1,43 @@
+<%@taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+	<title>Struts2 Showcase - CRUD Example</title>
+</head>
+<body>
+<div class="page-header">
+	<h1>Available Employees</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span3">
+			<ul class="nav nav-tabs nav-stacked">
+				<li class="active"><s:url var="url" namespace="/employee" action="list"/><s:a href="%{url}">List available Employees</s:a></li>
+				<li><s:url var="url" namespace="/employee" action="edit"/><s:a href="%{url}">Create/Edit Employee</s:a></li>
+				<li><s:url var="url" namespace="/skill" action="list"/><s:a href="%{url}">List available Skills</s:a></li>
+				<li><s:url var="url" namespace="/skill" action="edit"/><s:a href="%{url}">Create/Edit Skill</s:a></li>
+			</ul>
+		</div>
+		<div class="span9">
+
+				<table class="table table-striped table-bordered table-hover table-condensed">
+					<tr>
+						<th>Id</th>
+						<th>First Name</th>
+						<th>Last Name</th>
+					</tr>
+					<s:iterator value="availableItems">
+						<tr>
+							<td><a href="<s:url action="edit-%{empId}" />"><s:property value="empId"/></a></td>
+							<td><s:property value="firstName"/></td>
+							<td><s:property value="lastName"/></td>
+						</tr>
+					</s:iterator>
+
+				</table>
+				<a href="<s:url action="edit-" includeParams="none"/>" class="btn btn-primary">Create new Employee</a>
+		</div>
+	</div>
+</div>
+</body>
+</html>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/empmanager/listSkills.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/empmanager/listSkills.jsp b/apps/showcase/src/main/webapp/WEB-INF/empmanager/listSkills.jsp
new file mode 100644
index 0000000..1c20253
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/empmanager/listSkills.jsp
@@ -0,0 +1,41 @@
+<%@taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+	<title>Struts2 Showcase - CRUD Example</title>
+</head>
+<body>
+<div class="page-header">
+	<h1>Available Skills</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span3">
+			<ul class="nav nav-tabs nav-stacked">
+				<li><s:url var="url" namespace="/employee" action="list"/><s:a href="%{url}">List available Employees</s:a></li>
+				<li><s:url var="url" namespace="/employee" action="edit"/><s:a href="%{url}">Create/Edit Employee</s:a></li>
+				<li class="active"><s:url var="url" namespace="/skill" action="list"/><s:a href="%{url}">List available Skills</s:a></li>
+				<li><s:url var="url" namespace="/skill" action="edit"/><s:a href="%{url}">Create/Edit Skill</s:a></li>
+			</ul>
+		</div>
+		<div class="span9">
+
+			<table class="table table-striped table-bordered table-hover table-condensed">
+				<tr>
+					<th>Name</th><th>Description</th>
+				</tr>
+				<s:iterator value="availableItems">
+					<tr>
+						<td><a href="<s:url action="edit"><s:param name="skillName" value="name"/></s:url>"><s:property value="name"/></a></td>
+						<td><s:property value="description"/></td>
+					</tr>
+				</s:iterator>
+			</table>
+
+			<a href="<s:url action="edit" includeParams="none"/>" class="btn btn-primary">Create new Skill</a>
+		</div>
+	</div>
+</div>
+</body>
+</html>
+

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/filedownload/index.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/filedownload/index.jsp b/apps/showcase/src/main/webapp/WEB-INF/filedownload/index.jsp
new file mode 100644
index 0000000..a8b7ef8
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/filedownload/index.jsp
@@ -0,0 +1,36 @@
+<%@ taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+    <title>Struts2 Showcase - File Download</title>
+</head>
+
+<body>
+	<div class="page-header">
+		<h1>File Download Example</h1>
+	</div>
+
+
+
+    <div class="container-fluid">
+	    <div class="row-fluid">
+		    <div class="span6" style="text-align: center;">
+			    <div class="alert alert-info">
+				    The browser should display the Struts logo.
+			    </div>
+
+			    <s:url var="url" action="download"/>
+			    <s:a href="%{url}" cssClass="btn btn-large btn-info"><i class="icon-picture"></i> Download image file.</s:a>
+		    </div>
+		    <div class="span6" style="text-align: center;">
+			    <div class="alert alert-info">
+				    The browser should prompt for a location to save the ZIP file.
+			    </div>
+
+			    <s:url var="url" action="download2"/>
+			    <s:a href="%{url}" cssClass="btn btn-large btn-info"><i class="icon-download-alt"></i> Download ZIP file.</s:a>
+		    </div>
+	    </div>
+    </div>
+</body>
+</html>
+

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/fileupload/multipleUploadUsingArray.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/fileupload/multipleUploadUsingArray.jsp b/apps/showcase/src/main/webapp/WEB-INF/fileupload/multipleUploadUsingArray.jsp
new file mode 100644
index 0000000..4c8167c
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/fileupload/multipleUploadUsingArray.jsp
@@ -0,0 +1,32 @@
+<%@ page
+		language="java"
+		contentType="text/html; charset=UTF-8"
+		pageEncoding="UTF-8"%>
+<%@ taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+	<title>Struts2 Showcase - Fileupload sample - Multiple fileupload using Array</title>
+</head>
+
+<body>
+<div class="page-header">
+	<h1>Fileupload sample - Multiple fileupload using Array</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span12">
+
+			<s:form action="doMultipleUploadUsingArray" method="POST" enctype="multipart/form-data">
+				<s:file label="File (1)" name="upload" />
+				<s:file label="File (2)" name="upload" />
+				<s:file label="FIle (3)" name="upload" />
+				<s:submit cssClass="btn btn-primary"/>
+			</s:form>
+
+		</div>
+	</div>
+</div>
+
+</body>
+</html>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/fileupload/multipleUploadUsingList.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/fileupload/multipleUploadUsingList.jsp b/apps/showcase/src/main/webapp/WEB-INF/fileupload/multipleUploadUsingList.jsp
new file mode 100644
index 0000000..a84ef6c
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/fileupload/multipleUploadUsingList.jsp
@@ -0,0 +1,32 @@
+<%@ page 
+	language="java" 
+	contentType="text/html; charset=UTF-8"
+    pageEncoding="UTF-8"%>
+<%@ taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+	<title>Struts2 Showcase - Fileupload sample - Multiple fileupload using List</title>
+</head>
+
+<body>
+<div class="page-header">
+	<h1>Fileupload sample - Multiple fileupload using List</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span12">
+
+			<s:form action="doMultipleUploadUsingList" method="POST" enctype="multipart/form-data">
+				<s:file label="File (1)" name="upload" />
+				<s:file label="File (2)" name="upload" />
+				<s:file label="FIle (3)" name="upload" />
+				<s:submit cssClass="btn btn-primary"/>
+			</s:form>
+
+		</div>
+	</div>
+</div>
+
+</body>
+</html>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/fileupload/upload-success.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/fileupload/upload-success.jsp b/apps/showcase/src/main/webapp/WEB-INF/fileupload/upload-success.jsp
new file mode 100644
index 0000000..6073d2a
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/fileupload/upload-success.jsp
@@ -0,0 +1,31 @@
+<%@ page 
+	language="java" 
+	contentType="text/html; charset=UTF-8"
+    pageEncoding="UTF-8"%>
+<%@ taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+	<title>Struts2 Showcase - Fileupload sample</title>
+</head>
+
+<body>
+<div class="page-header">
+	<h1>Fileupload sample</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span12">
+			<ul>
+		        <li>ContentType: <s:property value="uploadContentType" /></li>
+		        <li>FileName: <s:property value="uploadFileName" /></li>
+		        <li>File: <s:property value="upload" /></li>
+		        <li>Caption:<s:property value="caption" /></li>
+	        </ul>
+		</div>
+	</div>
+</div>
+
+</body>
+</html>
+

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/fileupload/upload.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/fileupload/upload.jsp b/apps/showcase/src/main/webapp/WEB-INF/fileupload/upload.jsp
new file mode 100644
index 0000000..cc770c4
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/fileupload/upload.jsp
@@ -0,0 +1,27 @@
+<%@ taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+    <title>Struts2 Showcase - Fileupload sample</title>
+</head>
+
+<body>
+    <div class="page-header">
+	    <h1>Fileupload sample</h1>
+    </div>
+
+    <div class="container-fluid">
+	    <div class="row-fluid">
+		    <div class="span12">
+			    <s:actionerror cssClass="alert alert-error"/>
+				<s:fielderror cssClass="alert alert-error"/>
+			    <s:form action="doUpload" method="POST" enctype="multipart/form-data">
+			        <s:file name="upload" label="File"/>
+			        <s:textfield name="caption" label="Caption"/>
+			        <s:submit cssClass="btn btn-primary"/>
+			    </s:form>
+		    </div>
+	    </div>
+    </div>
+</body>
+</html>
+

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/freemarker/customFreemarkerManagerUsage.ftl
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/freemarker/customFreemarkerManagerUsage.ftl b/apps/showcase/src/main/webapp/WEB-INF/freemarker/customFreemarkerManagerUsage.ftl
new file mode 100644
index 0000000..a1e14cf
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/freemarker/customFreemarkerManagerUsage.ftl
@@ -0,0 +1,34 @@
+<html>
+<head>
+	<title>Struts2 Showcase - Freemarker - CustomFreemarkerManager Usage</title>
+</head>
+<body>
+
+<div class="page-header">
+	<h1>Custom Freemarker Manager Usage</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span12">
+
+		<p>
+	This page shows a simple example of using a custom freemarker manager.
+	The custom freemarker manager put into freemarker model an util classed 
+	under the name 'customFreemarkerManagerUtil'. so one could use
+	<p/>
+	<ul>
+		<li>$ { customFreemarkerManagerUtil.getTodayDate() } - to get today's date</li>
+		<li>$ { customFreemarkerManagerUtil.todayDate } - to get today's date</li>
+		<li>$ { customFreemarkerManagerUtil.getTimeNow() } - to get the time now</li>
+		<li>$ { customFreemarkerManagerUtil.timeNow } - to get the time now</li>
+	</ul>
+	 
+	 Today's Date = <span id="todaysDate">${customFreemarkerManagerUtil.todayDate}</span><br/>
+	 Time now =  <span id="timeNow">${customFreemarkerManagerUtil.getTimeNow()}</span><br/>
+		</div>
+	</div>
+</div>
+</body>
+</html>
+

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/freemarker/index.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/freemarker/index.jsp b/apps/showcase/src/main/webapp/WEB-INF/freemarker/index.jsp
new file mode 100644
index 0000000..360c6cb
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/freemarker/index.jsp
@@ -0,0 +1,3 @@
+<% response.sendRedirect("/freemarker/customFreemarkerManagerDemo.action"); %>
+
+

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/freemarker/standardTags.ftl
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/freemarker/standardTags.ftl b/apps/showcase/src/main/webapp/WEB-INF/freemarker/standardTags.ftl
new file mode 100644
index 0000000..016e189
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/freemarker/standardTags.ftl
@@ -0,0 +1,24 @@
+<html>
+<head>
+	<title>Struts2 Showcase - Freemarker - Standard Struts Freemarker Tags</title>
+</head>
+<body>
+
+<div class="page-header">
+	<h1>Standard Struts Freemarker Tags</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span12">
+
+			<@s.form action="test">
+	            <@s.textfield label="Name" name="name"/>
+	            <@s.select label="Birth Month" headerValue="Select Month" list="months" />
+			</@s.form>
+
+		</div>
+	</div>
+</div>
+</body>
+</html>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/hangman/blank.ftl
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/hangman/blank.ftl b/apps/showcase/src/main/webapp/WEB-INF/hangman/blank.ftl
new file mode 100644
index 0000000..e69de29

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/hangman/hangmanAjax.ftl
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/hangman/hangmanAjax.ftl b/apps/showcase/src/main/webapp/WEB-INF/hangman/hangmanAjax.ftl
new file mode 100644
index 0000000..e433290
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/hangman/hangmanAjax.ftl
@@ -0,0 +1,247 @@
+<html>
+<head>
+	<title>Struts2 Showcase - Hangman (AJAX)</title>
+<@sx.head />
+</head>
+<body>
+<div class="page-header">
+	<h1>Hangman</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span12">
+
+			<script>
+				function destroyWidgets() {
+					var div = dojo.byId("updateCharacterAvailableDiv");
+					var anchors = div.getElementsByTagName("a");
+					dojo.lang.forEach(anchors, function (anchor) {
+						var widget = dojo.widget.byId(anchor);
+						widget.destroy();
+					});
+				}
+
+				var _listeners = {
+					guessMade:function (request, widget) {
+						var sourceId = widget.widgetId;
+						this.guessMadeFunc(sourceId);
+						this.updateCharacterAvailable(sourceId);
+						this.updateVocab(sourceId);
+						this.updateScaffold(sourceId);
+						this.updateGuessLeft(sourceId);
+					},
+					guessMadeFunc:function (sourceId) {
+						var requestAttr = { character:sourceId };
+						dojo.io.bind({
+							url:"<@s.url action="guessCharacter" namespace="/hangman" />",
+							load:function (type, data, event) {
+
+							},
+							mimetype:"text/html",
+							content:requestAttr
+						});
+					},
+					updateCharacterAvailable:function (sourceId) {
+						dojo.io.bind({
+							url:"<@s.url action="updateCharacterAvailable" namespace="/hangman/ajax" />",
+							load:function (type, data, event) {
+								var div = dojo.byId("updateCharacterAvailableDiv");
+								destroyWidgets();
+								div.innerHTML = data;
+
+								try {
+									var xmlParser = new dojo.xml.Parse();
+									var frag = xmlParser.parseElement(div, null, true);
+									dojo.widget.getParser().createComponents(frag);
+									// eval any scripts being returned
+									var scripts = div.getElementsByTagName('script');
+									for (var i = 0; i < scripts.length; i++) {
+										eval(scripts[i].innerHTML);
+									}
+								}
+								catch (e) {
+									alert('dojo error ' + e);
+									dojo.debug("auto-build-widgets error: " + e);
+								}
+							},
+							mimetype:"text/html"
+						});
+					},
+					updateVocab:function (sourceId) {
+						dojo.io.bind({
+							url:"<@s.url action="updateVocabCharacters" namespace="/hangman/ajax" />",
+							load:function (type, data, event) {
+								var div = dojo.byId("updateVocabDiv");
+								div.innerHTML = data;
+
+								try {
+									var xmlParser = new dojo.xml.Parse();
+									var frag = xmlParser.parseElement(div, null, true);
+
+									var scripts = div.getElementsByTagName("script");
+									for (var i = 0; i < scripts.length; i++) {
+										eval(scripts[i].innerHTML);
+									}
+								}
+								catch (e) {
+									alert("dojo error" + e);
+									dojo.debug("auto-build-widgets error: " + e);
+								}
+							},
+							mimetype:"text/html"
+						});
+					},
+					updateScaffold:function (sourceId) {
+						dojo.io.bind({
+							url:"<@s.url action="updateScaffold" namespace="/hangman/ajax" />",
+							load:function (type, data, event) {
+								var div = dojo.byId("updateScaffoldDiv");
+								div.innerHTML = data;
+
+								try {
+									var xmlParser = new dojo.xml.Parse();
+									var frag = xmlParser.parseElement(div, null, true);
+
+									var scripts = div.getElementsByTagName("script");
+									for (var i = 0; i < scripts.length; i++) {
+										eval(scripts[i].innerHTML);
+									}
+								}
+								catch (e) {
+									alert("dojo error" + e);
+									dojo.debug("auto-build-widgets error: " + e);
+								}
+							},
+							mimetype:"text/html"
+						});
+					},
+					updateGuessLeft:function (sourceId) {
+						dojo.io.bind({
+							url:"<@s.url action="updateGuessLeft" namespace="/hangman/ajax" />",
+							load:function (type, data, event) {
+								var div = dojo.byId("updateGuessLeftDiv");
+								div.innerHTML = data;
+
+								try {
+									var xmlParser = new dojo.xml.Parse();
+									var frag = xmlParser.parseElement(div, null, true);
+
+									var scripts = div.getElementsByTagName("script");
+									for (var i = 0; i < scripts.length; i++) {
+										eval(scripts[i].innerHTML);
+									}
+								}
+								catch (e) {
+									alert("dojo error" + e);
+									dojo.debug("auto-build-widgets error: " + e);
+								}
+							},
+							mimetype:"text/html"
+						});
+					}
+				};
+				dojo.event.topic.subscribe("topicGuessMade", _listeners, "guessMade");
+			</script>
+
+			<table bgcolor="green">
+				<tr>
+					<td>
+					<@s.url id="url" value="/hangman/images/hangman.png" />
+						<img alt="Hangman" src="<@s.property value="%{#url}" />"
+						     width="197" height="50" border="0"/>
+					</td>
+					<td width="70" align="right">
+					<#-- Guesses Left -->
+						<div id="updateGuessLeftDiv">
+						<@s.set name="guessLeftImageName" value="%{'Chalkboard_'+hangman.guessLeft()+'.png'}" />
+						<@s.url id="url" value="%{'/hangman/images/'+#guessLeftImageName}" />
+							<img alt="No. Guesses Left"
+							     src="<@s.property value="%{#url}"/>" width="20" height="20" border="0"/>
+						</div>
+					</td>
+					<td>
+					<@s.url id="url" value="/hangman/images/guesses-left.png" />
+						<img alt="Guesses Left"
+						     src="<@s.property value="%{#url}" />" width="164" height="11" border="0"/>
+					</td>
+				</tr>
+				<tr>
+					<td></td>
+					<td align="left">
+					<#-- Display Scaffold -->
+						<div id="updateScaffoldDiv">
+						<@s.set name="scaffoldImageName" value="%{'scaffold_'+hangman.guessLeft()+'.png'}" />
+						<@s.url id="url" value="%{'/hangman/images/'+#scaffoldImageName}" />
+							<img src="<@s.property value="%{#url}" />" border="0"/>
+						</div>
+					</td>
+					<td></td>
+				</tr>
+				<tr>
+					<td width="160">
+						<p align="right">
+						<@s.url id="url" value="/hangman/images/guess.png" />
+							<img alt="Current Guess" src="<@s.property value="%{#url}" />"
+							     align="MIDDLE" width="127" height="20" border="0"/></p>
+					</td>
+					<td>
+					<#-- Display Vacab  -->
+						<div id="updateVocabDiv">
+						<@s.iterator id="currentCharacter" value="%{hangman.vocab.inCharacters()}" stat="stat">
+							<#if hangman.characterGuessedBefore(currentCharacter)>
+								<@s.set name="chalkboardImageName" value="%{'Chalkboard_'+#currentCharacter.toString()+'.png'}" />
+								<@s.url id="url" value="%{'/hangman/images/'+#chalkboardImageName}" />
+								<img height="36" alt="<@s.property value="%{#currentCharacter}" />"
+								     src="<@s.property value="%{#url}" />" width="36" border="0"/>
+							<#else>
+								<@s.url id="url" value="/hangman/images/Chalkboard_underscroll.png" />
+								<img height="36" alt="_"
+								     src="<@s.property value="%{#url}" />" width="36" border="0"/>
+							</#if>
+						</@s.iterator>
+						</div>
+					</td>
+				</tr>
+				<tr>
+					<td valign="top">
+						<p align="right">
+						<@s.url id="url" value="/hangman/images/choose.png" />
+							<img alt="Choose" src="<@s.property value="%{#url}" />"
+							     height="20" width="151" border="0"/>
+						</p>
+					</td>
+					<td width="330">
+
+					<#-- Show Characters Available -->
+						<div id="updateCharacterAvailableDiv">
+						<@s.iterator id="currentCharacter" value="%{hangman.charactersAvailable}" status="stat">
+							<@s.set name="chalkboardImageName" value="%{'Chalkboard_'+#currentCharacter+'.png'}" />
+							<@s.url id="chalkboardImageUrl" value="%{'/hangman/images/'+#chalkboardImageName}" />
+							<@s.url id="spacerUrl" value="/hangman/images/letter-spacer.png" />
+
+							<@s.url id="blankUrl" value="ajax/blank.action" includeContext="false" />
+							<@sx.a  id="%{#currentCharacter}"
+							beforeNotifyTopics="topicGuessMade"
+							showErrorTransportText="true">
+								<img height="36" alt="" src="<@s.property value="%{#chalkboardImageUrl}" />" width="36" border="0"/>
+							</@sx.a>
+						</@s.iterator>
+						</div>
+
+
+					</td>
+				</tr>
+				<tr>
+					<td>
+
+					</td>
+				</tr>
+			</table>
+		</div>
+	</div>
+</div>
+</body>
+</html>
+
+

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/hangman/hangmanNonAjax.ftl
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/hangman/hangmanNonAjax.ftl b/apps/showcase/src/main/webapp/WEB-INF/hangman/hangmanNonAjax.ftl
new file mode 100644
index 0000000..6bfd8ea
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/hangman/hangmanNonAjax.ftl
@@ -0,0 +1,144 @@
+<html>
+<head>
+	<title>Struts2 Showcase - Hangman</title>
+</head>
+<body>
+<div class="page-header">
+	<h1>Hangman</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span12">
+		<table>
+		  <tr>
+		    <td>
+		    <@s.url id="url" value="/hangman/images/hangman.png" />
+		    <img alt="Hangman" src="<@s.property value="%{#url}" />"
+		           width="197" height="50" border="0"/>
+		    </td>
+		    <td width="70" align="right">
+		      <#-- Guesses Left -->
+		      <div id="updateGuessLeftDiv">
+		      <#if (hangman.guessLeft() >= 0)>
+		      <@s.set name="guessLeftImageName" value="%{'Chalkboard_'+hangman.guessLeft()+'.png'}" />
+		      <@s.url id="url" value="%{'/hangman/images/'+#guessLeftImageName}" />
+		      <img alt="No. Guesses Left"
+		           src="<@s.property value="%{#url}"/>" width="20" height="20" border="0" />
+		      </#if>
+		      </div>
+		    </td>
+		    <td>
+		        <@s.url id="url" value="/hangman/images/guesses-left.png" />
+		        <img alt="Guesses Left"
+		            src="<@s.property value="%{#url}" />" width="164" height="11" border="0"/>
+		    </td>
+		  </tr>
+		  <tr>
+		    <td></td>
+		    <td align="left">
+		    <#-- Display Scaffold -->
+		    <div id="updateScaffoldDiv">
+		        <@s.set name="scaffoldImageName" value="%{'scaffold_'+hangman.guessLeft()+'.png'}" />
+		        <@s.url id="url" value="%{'/hangman/images/'+#scaffoldImageName}" />
+		        <img src="<@s.property value="%{#url}" />" border="0"/>
+		    </div>
+		    </td>
+		    <td></td>
+		    </tr>
+		  <tr>
+		    <td width="160">
+		      <p align="right">
+		        <@s.url id="url" value="/hangman/images/guess.png" />
+		        <img alt="Current Guess" src="<@s.property value="%{#url}" />"
+		           align="MIDDLE" width="127" height="20" border="0"/></p>
+		    </td>
+		    <td>
+		    <#-- Display Vacab  -->
+		    <div id="updateVocabDiv">
+		    <#if hangman.gameEnded()>
+				<@s.iterator id="currentCharacter" value="%{hangman.vocab.inCharacters()}" stat="stat">
+					<@s.url id="url" value="%{'/hangman/images/Chalkboard_'+#currentCharacter.toString()+'.png'}" />
+					<img height="36" alt="<@s.property value="%{#currentCharacter}" />"
+				            src="<@s.property value="%{#url}" />" width="36" border="0" />
+				</@s.iterator>
+			<#else>
+		    <@s.iterator id="currentCharacter" value="%{hangman.vocab.inCharacters()}" stat="stat">
+		        <#if hangman.characterGuessedBefore(currentCharacter)>
+		            <@s.set name="chalkboardImageName" value="%{'Chalkboard_'+#currentCharacter.toString()+'.png'}" />
+		            <@s.url id="url" value="%{'/hangman/images/'+#chalkboardImageName}" />
+		            <img height="36" alt="<@s.property value="%{#currentCharacter}" />"
+		                src="<@s.property value="%{#url}" />" width="36" border="0"/>
+		        <#else>
+		            <@s.url id="url" value="/hangman/images/Chalkboard_underscroll.png" />
+		            <img height="36" alt="_"
+		                src="<@s.property value="%{#url}" />" width="36" border="0"/>
+		        </#if>
+			</@s.iterator>
+			</#if>
+			</div>
+		    </td>
+		  </tr>
+		  <tr>
+		    <td valign="top">
+		      <p align="right">
+		        <@s.url id="url" value="/hangman/images/choose.png" />
+		        <img alt="Choose" src="<@s.property value="%{#url}" />"
+		             height="20" width="151" border="0"/>
+		      </p>
+		    </td>
+		    <td width="330">
+
+		    <#-- Show Characters Available -->
+		    <div id="updateCharacterAvailableDiv">
+		    <#if hangman.gameEnded()>
+			<@s.set name="winImageName" value="%{'you-win.png'}" />
+			<@s.set name="looseImageName" value="%{'you-lose.png'}" />
+			<@s.set name="startImageName" value="%{'start.png'}" />
+			<@s.url id="winImageUrl" value="%{'/hangman/images/'+#winImageName}"  />
+			<@s.url id="looseImageUrl" value="%{'/hangman/images/'+#looseImageName}" />
+			<@s.url id="startImageUrl" value="%{'/hangman/images/'+#startImageName}" />
+			<@s.url id="startHref" action="hangmanNonAjax" namespace="/hangman" />
+
+			<#if hangman.isWin()>
+			<img src="<@s.property value="%{#winImageUrl}" />" width="341" height="44" />
+			<#else>
+			<img src="<@s.property value="%{#looseImageUrl}" />" width="381" height="44" />
+			</#if>
+			<@s.a href="%{#startHref}">
+				<img src="<@s.property value="%{#startImageUrl}" />" width="250" height="43" />
+			</@s.a>
+			<#else>
+			<@s.iterator id="currentCharacter" value="%{hangman.charactersAvailable}" status="stat">
+		      <@s.set name="chalkboardImageName" value="%{'Chalkboard_'+#currentCharacter+'.png'}" />
+		      <@s.url id="chalkboardImageUrl" value="%{'/hangman/images/'+#chalkboardImageName}" />
+		      <@s.url id="spacerUrl" value="/hangman/images/letter-spacer.png" />
+		      <@s.url id="url" action="guessCharacterNonAjax" namespace="/hangman">
+		        <@s.param name="character" value="%{#currentCharacter}" />
+		      </@s.url>
+
+		      <@s.a href="%{#url}"
+		              id="%{#currentCharacter}"
+		              >
+		        <img height="36" alt="" src="<@s.property value="%{#chalkboardImageUrl}" />" width="36" border="0" />
+		      </@s.a>
+			</@s.iterator>
+			</#if>
+			</div>
+
+
+		   </td>
+		  </tr>
+		  <tr>
+		    <td>
+
+		    </td>
+		  </tr>
+		</table>
+		</div>
+	</div>
+</div>
+</body>
+</html>
+
+

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/hangman/updateCharacterAvailable.ftl
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/hangman/updateCharacterAvailable.ftl b/apps/showcase/src/main/webapp/WEB-INF/hangman/updateCharacterAvailable.ftl
new file mode 100644
index 0000000..84281d0
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/hangman/updateCharacterAvailable.ftl
@@ -0,0 +1,45 @@
+<#if hangman.gameEnded()>
+	<@s.set name="winImageName" value="%{'you-win.png'}" />
+	<@s.set name="looseImageName" value="%{'you-lose.png'}" />
+	<@s.set name="startImageName" value="%{'start.png'}" />
+	<@s.url id="winImageUrl" value="%{'/hangman/images/'+#winImageName}"  />
+	<@s.url id="looseImageUrl" value="%{'/hangman/images/'+#looseImageName}" />
+	<@s.url id="startImageUrl" value="%{'/hangman/images/'+#startImageName}" />
+	<@s.url id="startHref" action="hangmanAjax" namespace="/hangman" />
+	
+	<#if hangman.isWin()>
+	<img src="<@s.property value="%{#winImageUrl}" />" width="341" height="44" />
+	<#else>
+	<img src="<@s.property value="%{#looseImageUrl}" />" width="381" height="44" />
+	</#if>
+	<@s.a href="%{#startHref}">
+		<img src="<@s.property value="%{#startImageUrl}" />" width="250" height="43" />
+	</@s.a>
+<#else>
+<@s.iterator id="currentCharacter" value="%{hangman.charactersAvailable}" status="stat">
+      <@s.set name="chalkboardImageName" value="%{'Chalkboard_'+#currentCharacter+'.png'}" />
+      <@s.url id="chalkboardImageUrl" value="%{'/hangman/images/'+#chalkboardImageName}" />
+      <@s.url id="spacerUrl" value="/hangman/images/letter-spacer.png" />
+      <@s.url id="blankUrl" value="ajax/blank.action" includeContext="false" />
+      
+      <@sx.a  id="%{#currentCharacter}" 
+      		  afterNotifyTopics="topicGuessMade"
+      		  showErrorTransportText="true">
+      	<img height="36" alt="" src="<@s.property value="%{#chalkboardImageUrl}" />" width="36" border="0" />
+      </@sx.a>
+      
+      <#--
+      <a href="#" id="<@s.property value="%{#currentCharacter}"/>" >
+      	<img height="36" alt="" src="<@s.property value="%{#chalkboardImageUrl}" />" width="36" border="0" />
+      </a>
+      
+      <script>
+      	// var anchor = dojo.byId("<@s.property value="%{#currentCharacter}" />");
+      	var anchor = document.getElementById("<@s.property value="%{#currentCharacter}" />");
+      	dojo.event.connect(anchor, "onclick", function(event) {
+      		dojo.event.topic.publish("topicGuessMade", "<@s.property value="%{#currentCharacter}" />");
+      	});
+      </script>
+      -->
+</@s.iterator>
+</#if>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/hangman/updateGuessLeft.ftl
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/hangman/updateGuessLeft.ftl b/apps/showcase/src/main/webapp/WEB-INF/hangman/updateGuessLeft.ftl
new file mode 100644
index 0000000..8b5ef4e
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/hangman/updateGuessLeft.ftl
@@ -0,0 +1,7 @@
+<#if (hangman.guessLeft() >= 0)>
+	<@s.set name="guessLeftImageName" value="%{'Chalkboard_'+hangman.guessLeft()+'.png'}" />
+    <@s.url id="url" value="%{'/hangman/images/'+#guessLeftImageName}" />
+    <img alt="No. Guesses Left"
+      	   src="<@s.property value="%{#url}"/>" width="20" height="20" border="0" />
+</#if>
+      	   
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/hangman/updateScaffold.ftl
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/hangman/updateScaffold.ftl b/apps/showcase/src/main/webapp/WEB-INF/hangman/updateScaffold.ftl
new file mode 100644
index 0000000..afd11b6
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/hangman/updateScaffold.ftl
@@ -0,0 +1,3 @@
+	<@s.set name="scaffoldImageName" value="%{'scaffold_'+hangman.guessLeft()+'.png'}" />
+    <@s.url id="url" value="%{'/hangman/images/'+#scaffoldImageName}" />
+    <img src="<@s.property value="%{#url}" />" border="0"/>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/hangman/updateVocabCharacters.ftl
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/hangman/updateVocabCharacters.ftl b/apps/showcase/src/main/webapp/WEB-INF/hangman/updateVocabCharacters.ftl
new file mode 100644
index 0000000..d4b370b
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/hangman/updateVocabCharacters.ftl
@@ -0,0 +1,20 @@
+<#if hangman.gameEnded()>
+<@s.iterator id="currentCharacter" value="%{hangman.vocab.inCharacters()}" stat="stat">
+	<@s.url id="url" value="%{'/hangman/images/Chalkboard_'+#currentCharacter.toString()+'.png'}" />
+	<img height="36" alt="<@s.property value="%{#currentCharacter}" />"
+		 src="<@s.property value="%{#url}" />" width="36" border="0" />
+</@s.iterator>
+<#else>
+<@s.iterator id="currentCharacter" value="%{hangman.vocab.inCharacters()}" stat="stat">
+    	<#if hangman.characterGuessedBefore(currentCharacter)>
+    		<@s.set name="chalkboardImageName" value="%{'Chalkboard_'+#currentCharacter.toString()+'.png'}" />
+    		<@s.url id="url" value="%{'/hangman/images/'+#chalkboardImageName}" />
+    		<img height="36" alt="<@s.property value="%{#currentCharacter}" />"
+        		src="<@s.property value="%{#url}" />" width="36" border="0"/>
+    	<#else>
+    		<@s.url id="url" value="/hangman/images/Chalkboard_underscroll.png" />
+    		<img height="36" alt="_"
+        		src="<@s.property value="%{#url}" />" width="36" border="0"/>
+    	</#if>
+</@s.iterator>
+</#if>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/help.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/help.jsp b/apps/showcase/src/main/webapp/WEB-INF/help.jsp
new file mode 100644
index 0000000..08d84ac
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/help.jsp
@@ -0,0 +1,32 @@
+<%@taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+    <title>Struts2 Showcase . Getting Support</title>
+</head>
+
+<body>
+	<div class="page-header">
+		<h1>Getting support</h1>
+	</div>
+
+
+	<div class="container-fluid">
+		<div class="row-fluid">
+			<div class="span4" style="text-align: center;">
+				<img src='<s:url value="/images/struts.gif"/>' alt="Struts Logo" width="290" height="80"/>
+			</div>
+			<div class="span4" style="text-align: center;">
+				<div class="alert alert-info">
+					Use this mailing list if you encounter problems while developing and using with Struts.
+				</div>
+				<a href="http://struts.apache.org/mail.html" class="btn btn-large btn-info"><i class="icon-share"></i> User List</a>
+			</div>
+			<div class="span4" style="text-align: center;">
+				<div class="alert alert-info">
+					The Struts 2 website.
+				</div>
+				<a href="http://struts.apache.org/2.x/" class="btn btn-large btn-info"><i class="icon-share"></i> Struts 2</a>
+		</div>
+	</div>
+</body>
+</html>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/integration/modelDriven.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/integration/modelDriven.jsp b/apps/showcase/src/main/webapp/WEB-INF/integration/modelDriven.jsp
new file mode 100644
index 0000000..dc0b1f4
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/integration/modelDriven.jsp
@@ -0,0 +1,44 @@
+<%@ taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+	<title>Struts2 Showcase - Struts1 Integration</title>
+	<s:head/>
+</head>
+
+<body>
+
+<div class="page-header">
+	<h1>Struts1 Integration</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span12">
+
+
+			<s:form action="saveGangster" namespace="/integration">
+
+				<s:textfield
+						label="Gangster Name"
+						name="name"/>
+				<s:textfield
+						label="Gangster Age"
+						name="age"/>
+				<s:checkbox
+						label="Gangster Busted Before"
+						name="bustedBefore"/>
+				<s:textarea
+						cols="30"
+						rows="5"
+						label="Gangster Description"
+						name="description"/>
+				<s:submit cssClass="btn btn-primary"/>
+
+			</s:form>
+
+
+		</div>
+	</div>
+</div>
+</body>
+</html>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/integration/modelDrivenResult.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/integration/modelDrivenResult.jsp b/apps/showcase/src/main/webapp/WEB-INF/integration/modelDrivenResult.jsp
new file mode 100644
index 0000000..7d11f4c
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/integration/modelDrivenResult.jsp
@@ -0,0 +1,43 @@
+<%@ taglib prefix="s" uri="/struts-tags" %>
+<html>
+<head>
+	<title>Struts2 Showcase - Struts1 Integration - Result</title>
+	<style type="text/css">
+		.label {
+			background-color: #ffffff;
+			color: #000000;
+			text-shadow: none;
+			font-weight: bold;
+		}
+	</style>
+</head>
+
+<body>
+
+<div class="page-header">
+	<h1>Struts1 Integration - Result</h1>
+</div>
+
+<div class="container-fluid">
+	<div class="row-fluid">
+		<div class="span12">
+
+			<s:actionmessage cssClass="alert alert-info"/>
+			<s:label
+					label="Gangster Name"
+					name="name" /><br/>
+			<s:label
+					label="Gangster Age"
+					name="age" /><br/>
+			<s:label
+					label="Busted Before"
+					name="bustedBefore" /><br/>
+			<s:label
+					label="Gangster Description"
+					name="description" /><br/>
+
+		</div>
+	</div>
+</div>
+</body>
+</html>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/demo.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/demo.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/demo.jsp
new file mode 100644
index 0000000..e69de29

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/example-action.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/example-action.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/example-action.jsp
new file mode 100644
index 0000000..aaf5ce9
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/example-action.jsp
@@ -0,0 +1,76 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<pre style="font-style: normal;">
+<span class="kw">package</span> org.apache.struts2.showcase.action;
+
+<span class="kw">import</span> java.util.Arrays;
+<span class="kw">import</span> java.util.Date;
+<span class="kw">import</span> java.util.HashMap;
+<span class="kw">import</span> java.util.List;
+<span class="kw">import</span> java.util.Map;
+
+<span class="kw">import</span> com.opensymphony.xwork2.ActionSupport;
+
+<span class="kw">public class</span> ExampleAction <span class="kw">extends</span> ActionSupport {
+    <span class="kw">public static final</span> String CONSTANT = "Struts Rocks!";
+        
+    <span class="kw">public static</span> Date getCurrentDate() {
+        return new Date();
+    }
+    
+    <span class="kw">public</span> String getName() {
+        return "John Galt";
+    }
+
+    <span class="kw">public</span> String[] getBands() {
+        return new String[] { "Pink Floyd", "Metallica", "Guns & Roses" };
+    }
+
+    <span class="kw">public</span> List&lt;String&gt; getMovies() {
+        return Arrays.asList("Lord of the Rings", "Matrix");
+    }
+
+    <span class="kw">public</span> Book getBook() {
+        <span class="kw">return</span> new Book("Iliad", "Homer");
+    }
+
+    <span class="kw">public</span> Map&lt;String, Book&gt; getBooks() {
+        Map&lt;String, Book&gt; books = new HashMap&lt;String, Book&gt;();
+        books.put("Iliad", new Book("Iliad", "Homer"));
+        books.put("The Republic", new Book("The Replublic", "Plato"));
+        books.put("Thus Spake Zarathustra", new Book("Thus Spake Zarathustra",
+            "Friedrich Nietzsche"));
+        return books;
+    }
+}
+
+<span class="kw">class</span> Book {
+    <span class="kw">private</span> String title;
+    <span class="kw">private</span> String author;
+
+    <span class="kw">public</span> Book(String title, String author) {
+        this.title = title;
+        this.author = author;
+    }
+
+    <span class="kw">public</span> String getTitle() {
+        <span class="kw">return</span> title;
+    }
+
+    <span class="kw">public void</span> setTitle(String title) {
+        this.title = title;
+    }
+
+    <span class="kw">public</span> String getAuthor() {
+        return author;
+    }
+
+    <span class="kw">public void</span> setAuthor(String author) {
+        this.author = author;
+    }
+}
+</pre>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/index.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/index.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/index.jsp
new file mode 100644
index 0000000..987a39a
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/index.jsp
@@ -0,0 +1,241 @@
+<%@ page contentType="text/html;charset=UTF-8" language="java" %>
+<%@ taglib prefix="s" uri="/struts-tags" %>
+<%@ taglib prefix="sx" uri="/struts-dojo-tags" %>
+
+<html>
+<head>
+    <title>OGNL and tags demo</title>
+    <s:url var="struts" value="/struts" includeParams="none"/>
+    <s:url var="jspEval" action="jspEval" namespace="/nodecorate" includeParams="none"/>
+    <s:url var="viewClass" value="/interactive/example-action.jsp" includeParams="none"/>
+    <s:url var="ognlBase" value="/interactive/ognl_" includeParams="none"/>
+    <s:url var="jspBase" value="/interactive/jsp_" includeParams="none"/>
+    
+    <script src="${struts}/webconsole.js"></script>
+    <sx:head/>
+    <script>
+        var index = -1;
+        var runningOgnl = true;
+        var ognlBase = "${ognlBase}";
+        var jspBase = "${jspBase}";
+        var ognlCount = 9;
+        var jspCount = 5;
+        
+        dojo.addOnLoad(function() {
+            var classSrc = dojo.byId("classSrc");
+            dojo.io.updateNode(classSrc, "${viewClass}");
+            dojo.html.hide("previous");
+            dojo.html.hide("next");
+        });
+        
+        dojo.event.topic.subscribe("/reloadGuide", function() {
+            next();
+        });
+        
+        function startOgnl() {
+            selectOGNLTab();
+            index = -1;
+            runningOgnl = true;
+            change(1);
+            updateNavigation();
+        }
+        
+        function startJSP() {
+            selectJSPTab();
+            index = -1;
+            runningOgnl = false;
+            change(1);
+            updateNavigation();
+        }
+        
+        function execOgnl(id) {
+            var exp = dojo.string.trim(dojo.byId(id ? id : "example").innerHTML);
+            dojo.byId("wc-command").value = exp;
+            
+            keyEvent({keyCode : 13}, '${jspEval}');
+        }
+        
+        function execJSP(id) {
+            var exp = dojo.string.trim(dojo.byId(id ? id : "example").innerHTML);
+            dojo.byId("jsp").value = unscape(exp);
+            
+            dojo.event.topic.publish("/evalJSP")
+        }
+        
+        function unscape(str) {
+            return str.replace(/&amp;/gm, "&").replace(/&lt;/gm, "<").replace(/&gt;/gm, ">").replace(/&quot;/gm, '"');
+        }
+        
+        function selectClassSrcTab() {
+            dojo.widget.byId("mainTabContainer").selectTab("classTab");
+        }
+        
+        function selectJSPTab() {
+            dojo.widget.byId("mainTabContainer").selectTab("jspTab");
+        }
+        
+        function selectOGNLTab() {
+            dojo.widget.byId("mainTabContainer").selectTab("ognlTab");
+        }
+       
+        function change(delta) {
+            index+=delta;
+            
+            var url = (runningOgnl ? ognlBase : jspBase) + index + ".jsp";
+            var bind = dojo.widget.byId("guideBind");
+            bind.href = url;
+            dojo.event.topic.publish("/loadContent");
+            updateNavigation();
+        }
+        
+        function updateNavigation() {
+            if(index <= 0) {
+                dojo.html.hide("previous");
+            } else {
+                dojo.html.show("previous");
+            }
+            
+            var top = runningOgnl ? ognlCount : jspCount;
+            
+            if(index == top - 1) {
+                dojo.html.hide("next");
+            } else {
+                dojo.html.show("next");
+            }
+        }
+    </script>
+    
+    <style type="">
+        .wc-results {
+            overflow: auto; 
+            margin: 0px; 
+            padding: 5px; 
+            font-family: courier; 
+            color: white; 
+            background-color: black; 
+            height: 200px;
+        }
+        .wc-results pre {
+            display: inline;
+        }
+        .wc-command {
+            margin: 1px 0 0 0; 
+        }
+        .shell {
+            width: 100%;
+        }
+       
+        .jsp {
+            border-style: solid;
+            width: 100%;
+            height: 200px;
+        }
+        .jspResult {
+            border-style: none;
+            width: 100%;
+            height: 200px;
+            padding: 5px;
+        }
+        .jspResultHeader {
+            background-color: #818EBD;
+            color: white;
+            width: 100%;
+            height: 15px;
+        }
+        .jspResultHeader span {
+            padding: 5px;
+        }
+        .classSrc {
+            font-family:Courier;
+            font-size:11px;
+            line-height:13px;
+            overflow: auto; 
+            height: 400px;
+            width: 100%;
+        }
+        .tabContainer {
+            width: 1000px;
+            margin: 0 auto;
+        }
+        .guideContainer {
+            width: 600px;
+            border-width: 1px;
+            border-style: solid;
+            margin: 0 auto;
+        }
+        .guide {
+            padding: 5px;
+        }
+        pre {
+            font-family:Verdana,Geneva,Arial,Helvetica,sans-serif;
+            font-style: italic;
+        }
+        span.kw {
+            color: rgb(127, 0, 85);
+            font-weight: bold;;
+        }
+    </style>
+</head>
+
+<sx:bind id="guideBind" targets="guide" listenTopics="/loadContent"/>
+
+<body>
+    <sx:tabbedpanel id="mainTabContainer" cssClass="tabContainer">
+        <sx:div label="OGNL Console" id="ognlTab">
+            <div id="shell" class="shell">
+               <form onsubmit="return false" id="wc-form">
+                    <div class="wc-results" id="wc-result">
+                         Welcome to the OGNL console!
+                         <br />
+                         :-&gt;
+                    </div>
+                    <input type="hidden" name="debug" value="command" />
+                    OGNL Expression <input name="expression" onkeyup="keyEvent(event, '${jspEval}')" class="input-xxlarge wc-command" id="wc-command" type="text" />
+                </form>
+            </div>
+        </sx:div>
+        <sx:div label="JSP Console" id="jspTab">
+            <table style="width: 100%" cellpadding="1">
+                <tr valign="top">
+                    <td width="50%">
+                       <form theme="simple" namespace="/nodecorate" action="jspEval" method="post">
+                           <s:textarea cssClass="jsp" theme="simple" name="jsp" />
+                           <sx:submit
+                                value="Eval JSP Fragment" 
+                                href="%{#jspEval}" 
+                                targets="jspResult" 
+                                listenTopics="/evalJSP"/>
+                       </form>
+                    </td>
+                    <td width="50%">
+                        <div class="jspResultHeader">
+                            <span>JSP Eval Result</span>
+                        </div>
+                        <div id="jspResult" class="jspResult">
+                        </div>
+                    </td>
+                </tr>
+            </table>    
+        </sx:div>
+        <sx:div label="Class on top of the Value Stack" id="classTab">
+            <div id="classSrc" class="classSrc">
+            </div>
+        </sx:div>
+    </sx:tabbedpanel>
+    <br/><br/>
+    <div class="guideContainer">
+        <div class="jspResultHeader">
+            <span>Interactive Guide</span>
+        </div>
+        <sx:div id="guide" listenTopics="/reloadGuide" cssClass="guide">
+            <p><a href="#" onclick="startOgnl()">Start OGNL Interactive Demo</a></p>
+            <p><a href="#" onclick="startJSP()">Start JSP Interactive Demo</a></p>
+        </sx:div>   
+        <div>
+            <a href="#" id="previous" onclick="change(-1)" style="float: left"><< Previous</a>
+            <a href="#" id="next" onclick="change(1)" style="float: right">Next >></a>
+        </div>
+    </div>
+</body>
+
+</html>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_0.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_0.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_0.jsp
new file mode 100644
index 0000000..b6787d4
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_0.jsp
@@ -0,0 +1,62 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b>String Attributes</b>
+</p>
+<p>
+    Some tag attributes are expected to be Strings in which case String literals
+    can be passed as the value, like the <i>href</i> attribute in the <i>a</i> tag.
+</p>
+<p>
+    <i>
+        &lt;s:a href=&quot;http://struts.apache.org/&quot; /&gt; 
+    </i>
+</p>
+<p>
+   If the value that you want to use in one of these string literal attributes is stored on the Value Stack,
+   then the <i>%{#name}</i> syntax (alternative syntax) needs to be used. Assuming there is a value
+   with the name "url" stored on the stack:
+</p>
+<p>
+    <i>
+        &lt;s:a href=&quot;%{#url}&quot; /&gt;
+    </i>
+</p>
+<p>
+  will create an anchor and use the value of "url" for the <i>href</i> attribute.
+</p>
+<p>
+    <b>Value Attributes</b>
+</p>
+<p>
+    Other attributes expect an object as their value(not an string literal). In these attributes you can specify
+    the name of a variable stored on the Value Stack, and the tag will look it up and use it. Like the
+    <i>value</i> attribute in the <i>property</i> tag. Assuming there is an object stored on the Value Stack with
+    the name "movie", then:
+</p>
+<p>
+    <i>
+        &lt;s:property value=&quot;movie&quot; /&gt;
+    </i>
+</p>
+<p>
+  will print the value to the page. To pass an String literal to an attribute that expects a value use the <i>%{'string'}</i>
+  notation.
+</p>
+<p>
+  If you don't remember if an attribute expects an string literal or a value, you can always use the <i>%{value}</i> notation:
+</p>
+<p>
+    <i>
+        &lt;s:a href=&quot;%{'http://struts.apache.org/'}&quot; /&gt;
+        <br />
+        &lt;s:property value=&quot;%{#movie}&quot; /&gt;
+    </i>
+</p>
+<p>
+    <a href="#" onclick="window.open('http://struts.apache.org/2.x/docs/tag-syntax.html')">[More details]</a>
+</p>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_1.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_1.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_1.jsp
new file mode 100644
index 0000000..a96ab7a
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_1.jsp
@@ -0,0 +1,52 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b>Print property value, using the <i>property tag</i></b>
+</p>
+<p>
+    On the OGNL demo you learned how to access values from the Value Stack using OGNL expressions.
+    The <i>property</i> tag is used to print to the page the result of an OGNL expression. The expression
+    is specified in the <i>value</i> attribute.
+</p>
+<p>To print the value of the expression <i>name</i> to the page type:
+<p>
+    <i id="example0">
+        &lt;s:property value=&quot;name&quot; /&gt;
+    </i>
+</p>
+<p>
+    on the JSP console and hit enter. <a href="#" onclick="execJSP('example0')">Do it for me</a>
+</p>
+<p>
+    As you saw in the OGNL demo, to print a property of an object that is not on top of the stack,
+    use the <i>#object.property</i> notation.
+</p>
+<p>To print the value for the key "struts.view_uri" in <i>request</i> to the page type:
+<p>
+    <i id="example1">
+        &lt;s:property value=&quot;#request['struts.view_uri']&quot; /&gt;
+    </i>
+</p>
+<p>
+    on the JSP console and hit enter. <a href="#" onclick="execJSP('example1')">Do it for me</a>
+</p>
+<p>
+    <b>Print property value, using the <i>$</i> operator</b>
+</p>
+<p>Use the <i>${name}</i> notation to print values from the Value Stack to the page.
+<p>To print the value of the expression <i>name</i> to the page type:
+<p>
+    <i id="example2">
+        &#36;{name}
+    </i>
+</p>
+<p>
+    on the JSP console and hit enter. <a href="#" onclick="execJSP('example2')">Do it for me</a>
+</p>
+<p>
+    <a href="#" onclick="window.open('http://struts.apache.org/2.x/docs/property.html')">[More details]</a>
+</p>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_2.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_2.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_2.jsp
new file mode 100644
index 0000000..565a7ec
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_2.jsp
@@ -0,0 +1,54 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b><i>if</i> tag</b>
+</p>
+<p>
+    The <i>if</i> tag allows you to optionally execute a JSP section. Multiple <i>elseif</i> tags
+    and one <i>else</i> tag can be associated to an <i>if tag</i>.
+</p>
+<p>    
+    To say hello to John Galt type:
+</p>
+<p>
+    <pre id="example0">
+        &lt;s:if test="name == 'John Galt'"&gt;
+            Hi John
+        &lt;/s:if&gt;
+        &lt;s:else&gt;
+            I don't know you!
+        &lt;/s:else&gt;
+    </pre>
+</p>
+<p>
+    on the JSP console and hit enter. <a href="#" onclick="execJSP('example0')">Do it for me</a>
+</p>
+<p>
+    <b><i>iterator</i> tag</b>
+</p>
+<p>
+    The <i>iterator</i> tag loops over an <i>Iterable</i> object one object at a time into
+    the Value Stack (the value will be on top of the stack).
+</p>
+<p>    
+    To print the all the elements in the "bands" property type:
+</p>
+<p>
+    <pre id="example1">
+        &lt;s:iterator value="bands"&gt;
+            &lt;s:property /&gt;
+            &lt;br /&gt;
+        &lt;/s:iterator&gt;
+    </pre>
+</p>
+<p>
+    on the JSP console and hit enter. <a href="#" onclick="execJSP('example1')">Do it for me</a>
+</p>
+<p>
+    <a href="#" onclick="window.open('http://struts.apache.org/2.x/docs/property.html')">[More on the <i>if</i> tag]</a>
+    <a href="#" onclick="window.open('http://struts.apache.org/2.x/docs/iterator.html')">[More on the <i>iterator</i> tag]</a>
+</p>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_3.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_3.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_3.jsp
new file mode 100644
index 0000000..483db12
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_3.jsp
@@ -0,0 +1,65 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b><i>set</i> tag</b>
+</p>
+<p>
+    The <i>set</i> tag sets the variable with the name specified in the <i>name</i> attribute to 
+    the value specified in the <i>value</i> attribute in the scope
+    entered in the <i>scope</i> attribute. The available scopes are:
+    <ul>
+        <li>application - application scope according to servlet spec</li>
+        <li>session - session scope according to servlet spec</li>
+        <li>request - request scope according to servlet spec</li>
+        <li>page - page scope according to servlet sepc</li>
+        <li>action - the value will be set in the request scope and Struts' action context</li>
+        
+    </ul>
+</p>
+<p>    
+    This example sets <i>favouriteBand</i> in the request scope to the first element of the <i>bands</i> property:
+</p>
+<p>
+    <pre id="example0">
+        &lt;s:set name="favouriteBand" value="bands[0]" /&gt;
+        &lt;s:property value="#favouriteBand" /&gt;
+    </pre>
+</p>
+<p>
+    <a href="#" onclick="execJSP('example0')">Do it for me</a>
+</p>
+<p>
+    <b><i>url</i> tag</b>
+</p>
+<p>
+    The <i>url</i> tag is used to build urls (who would have guessed!). To build an url mapping to
+    an action, set the <i>namespace</i> and <i>action</i> attributes. The url will be stored under
+    the name specified in the <i>id</i> attribute. <b>url tag uses the <i>id</i> attribute while 
+    the <i>set</i> tag uses name</b>. To specify a value (no action lookup), just use the <i>value</i>
+    attribute. <i>param</i> tags can be nested inside the <i>url</i> tag to add parameters to the url.
+</p>
+<p>    
+    First link creates a url that maps to an action, second one creates a url to google, passing one parameter:
+</p>
+<p>
+    <pre id="example1">
+        &lt;s:url id="evalAction" namespace="/nodecorate" action="jspEval" /&gt;
+        &lt;s:a href="%{#evalAction}" &gt;Eval&lt;/s:a&gt;
+        
+        &lt;s:url id="google" value="http://www.google.com" &gt;
+            &lt;s:param name="q" value="%{'Struts 2'}" /&gt; 
+        &lt;/s:url&gt;
+        &lt;s:a href="%{#google}" &gt;Eval&lt;/s:a&gt;
+    </pre>
+</p>
+<p>
+   <a href="#" onclick="execJSP('example1')">Do it for me</a>
+</p>
+<p>
+    <a href="#" onclick="window.open('http://struts.apache.org/2.x/docs/set.html')">[More on the <i>set</i> tag]</a>
+    <a href="#" onclick="window.open('http://struts.apache.org/2.x/docs/url.html')">[More on the <i>url</i> tag]</a>
+</p>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_4.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_4.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_4.jsp
new file mode 100644
index 0000000..8d63ee5
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/jsp_4.jsp
@@ -0,0 +1,16 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b>More on JSP tags</b>
+</p>
+<p>
+  Struts 2 provides many more tags which you can learn about 
+  <a href="#" onclick="window.open('http://cwiki.apache.org/confluence/display/WW/Tag+Reference')">here</a>
+</p>
+<br/>
+You can keep playing with the JSP console or 
+<a href="#" onclick="startOgnl()">Start OGNL Interactive Demo</a>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_0.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_0.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_0.jsp
new file mode 100644
index 0000000..7f441e4
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_0.jsp
@@ -0,0 +1,30 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b>Accessing properties</b>
+</p>
+<p>
+    The framework uses a standard naming context to evaluate OGNL expressions. 
+    The top level object dealing with OGNL is a Map (usually referred as a context map or context).
+    OGNL has a notion of there being a root (or default) object within the context. 
+    In OGNL expressions, the properties of the root object can be referenced without any special "marker" notion.
+    References to other objects are marked with a pound sign (#).
+    
+    In this example (and in your JSP pages) the last action executed will be on the top of the stack. 
+</p>
+<p>    
+    <a href="#" onclick="selectClassSrcTab()">This action</a> is available on the third tab above. 
+    To access the <i>name</i> field type:
+</p>
+<p>
+    <i id="example">
+        name
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter. <a href="#" onclick="execOgnl()">Do it for me</a>
+</p>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_1.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_1.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_1.jsp
new file mode 100644
index 0000000..17505bd
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_1.jsp
@@ -0,0 +1,28 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b>Accessing nested properties</b>
+</p>
+<p>
+    To access nested properties, use the dot "." operator to concatenate the property names. The action
+    class has a <i>book</i> field, with <i>title</i> and <i>author</i> fields.
+</p>
+<p>
+    To access the name of the book type:
+</p>
+<p>
+    <i id="example">
+        book.title
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter. <a href="#" onclick="execOgnl()">Do it for me</a>
+</p>
+<br/>
+<p>
+    <a href="#" onclick="window.open('http://www.ognl.org/2.6.9/Documentation/html/LanguageGuide/properties.html')">[More details]</a>
+</p>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_2.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_2.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_2.jsp
new file mode 100644
index 0000000..c1716db
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_2.jsp
@@ -0,0 +1,43 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b>Accessing properties inside Arrays</b>
+</p>
+<p>
+    To access properties inside arrays, use the brackets "[]" operators with the desired index(starting from 0). The action
+    class has an array of String in the field <i>bands</i>.
+</p>
+<p>
+    To access the second element in the <i>bands</i> array type:
+</p>
+<p>
+    <i id="example0">
+        bands[1]
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter. <a href="#" onclick="execOgnl('example0')">Do it for me</a>
+</p>
+<p>
+    <b>Accessing properties inside Lists</b>
+</p>
+<p>Lists can be accessed on the same way. The action class has a List of String on the field <i>movies</i>.</p>
+<p>
+    To access the first element in the <i>movies</i> list type:
+</p>
+<p>
+    <i id="example1">
+        movies[0]
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter.  <a href="#" onclick="execOgnl('example1')">Do it for me</a>
+</p>
+<br/>
+<p>
+    <a href="#" onclick="window.open('http://www.ognl.org/2.6.9/Documentation/html/LanguageGuide/indexing.html#N10184')">[More details]</a>
+</p>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_3.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_3.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_3.jsp
new file mode 100644
index 0000000..03c3095
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_3.jsp
@@ -0,0 +1,54 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b>Accessing properties inside Maps</b>
+</p>
+<p>
+    To access properties inside maps, use the brackets "[]" operators with the desired key. The action
+    class has a map of Book objects in the field <i>books</i>.
+</p>
+<p>
+    To access the book with key "Iliad" in the <i>books</i> map type:
+</p>
+<p>
+    <i id="example0">
+        books['Iliad']
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter. <a href="#" onclick="execOgnl('example0')">Do it for me</a>
+</p>
+<p>If the key does not have spaces in it, you can access an element in the map, using the dot "." operator.</p>
+<p>
+    To access the book with key "Iliad" in the <i>books</i> map type:
+</p>
+<p>
+    <i id="example1">
+        books.Iliad
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter. <a href="#" onclick="execOgnl('example1')">Do it for me</a>
+</p>
+<p>
+    Note that the object returned is of type Book. If you want to access one of its properties, you can do so using the dot
+    "." operator as you did before.</p>
+<p>
+    To access the <i>author</i> property of the book with key "Iliad" in the <i>books</i> map type:
+</p>
+<p>
+    <i id="example2">
+        books['Iliad'].author
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter. <a href="#" onclick="execOgnl('example2')">Do it for me</a>
+</p>
+<br/>
+<p>
+    <a href="#" onclick="window.open('http://www.ognl.org/2.6.9/Documentation/html/LanguageGuide/indexing.html#N10184')">[More details]</a>
+</p>

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_4.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_4.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_4.jsp
new file mode 100644
index 0000000..7e158d5
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_4.jsp
@@ -0,0 +1,32 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b>Accessing properties on the stack</b>
+</p>
+<p>
+   Object that are not on the top of the Value Stack are accessed using the "#name" notation. 
+   Some objects are always pushed into the stack by Struts, like:
+</p>
+<ul>
+    <li>#application</li>
+    <li>#session</li>
+    <li>#request</li>
+    <li>#parameters</li>
+</ul>
+<p>To see the value of the first parameter type:</p>
+<p>
+    <i id="example">
+        #parameters['debug'][0]
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter.  <a href="#" onclick="execOgnl()">Do it for me</a>
+</p>
+<br/>
+<p>
+    <a href="#" onclick="window.open('http://struts.apache.org/2.x/docs/ognl.html')">[More details]</a>
+</p>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_5.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_5.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_5.jsp
new file mode 100644
index 0000000..5624567
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_5.jsp
@@ -0,0 +1,25 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b>Calling methods</b>
+</p>
+<p>
+  OGNL follows Java's syntax to execute a method.
+</p>
+<p>To execute the <i>getTitle()</i> method on the <i>book</i> object type:</p>
+<p>
+    <i id="example">
+        book.getTitle() 
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter.  <a href="#" onclick="execOgnl()">Do it for me</a>
+</p>
+<br/>
+<p>
+    <a href="#" onclick="window.open('http://www.ognl.org/2.6.9/Documentation/html/LanguageGuide/methods.html')">[More details]</a>
+</p>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_6.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_6.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_6.jsp
new file mode 100644
index 0000000..91466e1
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_6.jsp
@@ -0,0 +1,43 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b>Expressions</b>
+</p>
+<p>
+  OGNL supports expressions using primitive values.
+</p>
+<p>Arithmetic:</p>
+<p>
+    <i id="example0">
+        (6 - 2)/2
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter.  <a href="#" onclick="execOgnl('example0')">Do it for me</a>
+</p>
+<p>Logical:</p>
+<p>
+    <i id="example1">
+        (true || false) and true
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter.  <a href="#" onclick="execOgnl('example1')">Do it for me</a>
+</p>
+<p>Equality:</p>
+<p>
+    <i id="example2">
+        'a' == 'a'
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter.  <a href="#" onclick="execOgnl('example2')">Do it for me</a>
+</p>
+<p>
+    OGNL supports many more operators and expressions, see <a href="#" onclick="window.open('http://www.ognl.org/2.6.9/Documentation/html/LanguageGuide/apa.html#operators')">[Operators Reference]</a>
+    for more details.
+</p>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_7.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_7.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_7.jsp
new file mode 100644
index 0000000..a0318ab
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_7.jsp
@@ -0,0 +1,55 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p><b>Creating arrays</b></p>
+<p>
+    OGNL follows Java syntax to create arrys.
+</p>
+<p>
+    Create an array of integers:
+</p>
+<p>
+    <i id="example0">
+        new int[] {0, 1, 2}
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter. <a href="#" onclick="execOgnl('example0')">Do it for me</a>
+</p>
+<p><b>Creating lists</b></p>
+<p>
+    To create a list, enclose a list of comma separated expression in a pair of braces.
+</p>
+<p>
+    Create a list of Strings:
+</p>
+<p>
+    <i id="example1">
+        {'Is', 'there', 'any', 'body', 'out', 'there?'}
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter. <a href="#" onclick="execOgnl('example1')">Do it for me</a>
+</p>
+<p><b>Creating maps</b></p>
+<p>
+    To create a map, use the syntax #@MAP_TYPE@{key:value}.
+</p>
+<p>
+    Create a LinkedHashMap:
+</p>
+<p>
+    <i id="example2">
+        #@java.util.LinkedHashMap@{'name': 'John Galt', 'job' : 'Engineer'}
+    </i>
+</p>
+<p>
+    on the OGNL console and hit enter. <a href="#" onclick="execOgnl('example2')">Do it for me</a>
+</p>
+<br/>
+<p>
+    <a href="#" onclick="window.open('http://www.ognl.org/2.6.9/Documentation/html/LanguageGuide/collectionConstruction.html#listConstruction')">[More details]</a>
+</p>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/struts/blob/65eb9751/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_8.jsp
----------------------------------------------------------------------
diff --git a/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_8.jsp b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_8.jsp
new file mode 100644
index 0000000..3a2cc6e
--- /dev/null
+++ b/apps/showcase/src/main/webapp/WEB-INF/interactive/ognl_8.jsp
@@ -0,0 +1,18 @@
+<%
+    request.setAttribute("decorator", "none");
+    response.setHeader("Cache-Control","no-cache"); //HTTP 1.1
+    response.setHeader("Pragma","no-cache"); //HTTP 1.0
+    response.setDateHeader ("Expires", 0); //prevents caching at the proxy server
+%>
+<p>
+    <b>More on OGNL</b>
+</p>
+<p>
+  There are a lot of OGNL features that we have not covered on this short tutorial. 
+</p>
+<br/>
+<p>
+    To learn more see the <a href="#" onclick="window.open('http://www.ognl.org/2.6.9/Documentation/html/LanguageGuide/index.html')">[OGNL Documentation]</a>
+</p>
+You can keep playing with the OGNL console or 
+<a href="#" onclick="startJSP()">Start JSP Interactive Demo</a>
\ No newline at end of file


Mime
View raw message