tapestry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From build...@apache.org
Subject svn commit: r958985 [12/29] - in /websites/production/tapestry/content: ./ 2009/09/13/ 2009/10/27/ 2009/11/25/ 2010/07/18/ 2010/07/24/ 2010/10/11/ 2010/10/31/ 2010/11/18/ 2010/12/16/ 2010/12/17/ 2011/01/18/ 2011/03/23/ 2011/03/29/ 2011/03/30/ 2011/03/3...
Date Sun, 19 Jul 2015 21:21:30 GMT
Modified: websites/production/tapestry/content/environmental-services.html
==============================================================================
--- websites/production/tapestry/content/environmental-services.html (original)
+++ websites/production/tapestry/content/environmental-services.html Sun Jul 19 21:21:27 2015
@@ -27,6 +27,16 @@
   </title>
   <link type="text/css" rel="stylesheet" href="/resources/space.css">
 
+    <link href='/resources/highlighter/styles/shCoreCXF.css' rel='stylesheet' type='text/css' />
+  <link href='/resources/highlighter/styles/shThemeCXF.css' rel='stylesheet' type='text/css' />
+  <script src='/resources/highlighter/scripts/shCore.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushJava.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushXml.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushPlain.js' type='text/javascript'></script>
+  <script type="text/javascript">
+  SyntaxHighlighter.defaults['toolbar'] = false;
+  SyntaxHighlighter.all();
+  </script>
 
   <link href="/styles/style.css" rel="stylesheet" type="text/css"/>
 
@@ -75,9 +85,9 @@
 <p>A very common Environmental is <a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/services/javascript/JavaScriptSupport.html">JavaScriptSupport</a>, used when generating <a shape="rect" href="legacy-javascript.html">client-side JavaScript</a>.</p>
 
 <div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
+<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">
 
-  @Inject @Path(&quot;${tapestry.scriptaculous}/dragdrop.js&quot;)
+  @Inject @Path("${tapestry.scriptaculous}/dragdrop.js")
   private Asset dragDropLibrary;
 
   @Environmental
@@ -88,7 +98,7 @@
     javaScriptSupport.importJavaScriptLibrary(dragDropLibrary);
   }
 
-]]></script>
+</pre>
 </div></div>
 
 <p>Environmental services are, by their nature, per-thread (and therefore per-request).</p>
@@ -106,7 +116,7 @@
 <p>The relevant information could be exposed as an interface, TabModel.</p>
 
 <div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
+<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">
 public class TabGroup
 {
   @Inject
@@ -133,7 +143,7 @@ public class Tab
     ...
   }
 }
-]]></script>
+</pre>
 </div></div>
 
 <p>Notice that when pushing a value into the Environment, you identify its type as well as the instance. Environment maintains a number of stacks, one for each type. Thus, pushing a TabModel into the environment won't disturb the RenderSupport or other environmentals already there.</p>
@@ -159,12 +169,12 @@ public class Tab
 <p>If this is something that will occur frequently, it is possible to create a service implementation that is "backed" by the Environment. For example, RenderSupport is accessible as a normal injection, because a service is built for it in TapestryModule:</p>
 
 <div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[
+<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">
   public RenderSupport buildRenderSupport(EnvironmentalShadowBuilder builder)
   {
     return builder.build(RenderSupport.class);
   }
-]]></script>
+</pre>
 </div></div>
 
 <p>The EnvironmentShadowBuilder service creates a service implementation that delegates to the proper instance in the environment. The same technique can be used for your own services and environmentals.</p></div>

Modified: websites/production/tapestry/content/error-page-recipe.html
==============================================================================
--- websites/production/tapestry/content/error-page-recipe.html (original)
+++ websites/production/tapestry/content/error-page-recipe.html Sun Jul 19 21:21:27 2015
@@ -27,6 +27,16 @@
   </title>
   <link type="text/css" rel="stylesheet" href="/resources/space.css">
 
+    <link href='/resources/highlighter/styles/shCoreCXF.css' rel='stylesheet' type='text/css' />
+  <link href='/resources/highlighter/styles/shThemeCXF.css' rel='stylesheet' type='text/css' />
+  <script src='/resources/highlighter/scripts/shCore.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushJava.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushXml.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushPlain.js' type='text/javascript'></script>
+  <script type="text/javascript">
+  SyntaxHighlighter.defaults['toolbar'] = false;
+  SyntaxHighlighter.all();
+  </script>
 
   <link href="/styles/style.css" rel="stylesheet" type="text/css"/>
 
@@ -57,21 +67,13 @@
   </div>
 
 <div id="content">
-<div id="ConfluenceContent"><style type="text/css">/*<![CDATA[*/
-table.ScrollbarTable  {border: none;padding: 3px;width: 100%;padding: 3px;margin: 0px;background-color: #f0f0f0}
-table.ScrollbarTable td.ScrollbarPrevIcon {text-align: center;width: 16px;border: none;}
-table.ScrollbarTable td.ScrollbarPrevName {text-align: left;border: none;}
-table.ScrollbarTable td.ScrollbarParent {text-align: center;border: none;}
-table.ScrollbarTable td.ScrollbarNextName {text-align: right;border: none;}
-table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width: 16px;border: none;}
-
-/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="overriding-exception-reporting.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="overriding-exception-reporting.html">Overriding Exception Reporting</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="cookbook.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="cookbook.html">Cookbook</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="supporting-informal-parameters.html">Supporting Informal Parameters</a></td><td colspan="1" rowspan="1" class="ScrollbarNextIcon"><
 a shape="rect" href="supporting-informal-parameters.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div><div class="navmenu" style="float:right; background:#eee; margin:3px; padding:3px">
+<div id="ConfluenceContent"><div class="navmenu" style="float:right; background:#eee; margin:3px; padding:3px">
 <div class="error"><span class="error">Error formatting macro: contentbylabel: com.atlassian.confluence.api.service.exceptions.BadRequestException: Could not parse cql : null</span> </div></div><h1 id="ErrorPageRecipe-ServingTapestryPagesasServletErrorPages">Serving Tapestry Pages as Servlet Error Pages</h1><p>Do you want to dress up your site and use a snazzy Tapestry page instead of the default 404 error page? Using modern servlet containers, this is a snap!</p><p>Simply upgrade your application web.xml to the 2.4 version, and make a couple of changes:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>web.xml</b></div><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">&lt;?xml version="1.0" encoding="UTF-8"?&gt;
 
-&lt;web-app xmlns=&quot;http://java.sun.com/xml/ns/j2ee&quot; xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot;
-  xsi:schemaLocation=&quot;http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd&quot;
-  version=&quot;2.4&quot;&gt;
+&lt;web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
+  version="2.4"&gt;
 
   &lt;display-name&gt;Cookbook&lt;/display-name&gt;
   &lt;context-param&gt;
@@ -96,28 +98,28 @@ table.ScrollbarTable td.ScrollbarNextIco
   &lt;/error-page&gt;
 
 &lt;/web-app&gt;
-]]></script>
+</pre>
 </div></div><p>Tapestry's filter must be marked as a handler for both standard requests and errors. That's accomplished with the <code>&lt;dispatcher&gt;</code> elements inside the <code>&lt;filter-mapping&gt;</code> section.</p><p>You must then map error codes to Tapestry URLs. In this case, the 404 error is send to the <code>/error404</code> resource, which is really the "Error404" Tapestry page.</p><p>We'll create a simple Error404 page, one that displays a message and (in development mode) displays the details about the incoming request.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Error404.tml</b></div><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[&lt;html xmlns:t=&quot;http://tapestry.apache.org/schema/tapestry_5_4.xsd&quot;&gt;
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">&lt;html xmlns:t="http://tapestry.apache.org/schema/tapestry_5_4.xsd"&gt;
  &lt;head&gt;
 
         &lt;title&gt;Resource not found.&lt;/title&gt;
     &lt;/head&gt;
     &lt;body&gt;
 
-        &lt;div class=&quot;container&quot;&gt;
+        &lt;div class="container"&gt;
 
             &lt;h1&gt;Page or resource not found.&lt;/h1&gt;
 
-            &lt;t:if test=&quot;! productionMode&quot;&gt;
-                &lt;t:renderobject object=&quot;request&quot;/&gt;
+            &lt;t:if test="! productionMode"&gt;
+                &lt;t:renderobject object="request"/&gt;
             &lt;/t:if&gt;
         &lt;/div&gt;
 
     &lt;/body&gt;
-&lt;/html&gt;]]></script>
+&lt;/html&gt;</pre>
 </div></div><p>The page simply makes the request and productionMode properties available:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Error404.java</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[package com.example.newapp.pages;
+<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">package com.example.newapp.pages;
 
 import org.apache.tapestry5.SymbolConstants;
 import org.apache.tapestry5.annotations.Property;
@@ -138,8 +140,8 @@ public class Error404
 }
 
 
-]]></script>
-</div></div><p>The end-result, in when <em>not</em> in production mode, looks like this:</p><p><span class="confluence-embedded-file-wrapper image-center-wrapper confluence-embedded-manual-size"><img class="confluence-embedded-image confluence-content-image-border image-center" width="500" src="error-page-recipe.data/Resource_not_found_.png" data-image-src="/confluence/download/attachments/23336861/Resource_not_found_.png?version=1&amp;modificationDate=1428099193000&amp;api=v2" data-unresolved-comment-count="0" data-linked-resource-id="55476335" data-linked-resource-version="1" data-linked-resource-type="attachment" data-linked-resource-default-alias="Resource_not_found_.png" data-base-url="https://cwiki.apache.org/confluence" data-linked-resource-content-type="image/png" data-linked-resource-container-id="23336861" data-linked-resource-container-version="23"></span></p><div class="confluence-information-macro confluence-information-macro-information"><span class="aui-icon aui-icon-
 small aui-iconfont-info confluence-information-macro-icon"></span><div class="confluence-information-macro-body"><p>An issue with an application that has a root Index page is that any invalid path, which would normally generate a 404 error, is instead routed to the Index page (because the invalid path looks like page's activation context). See <a shape="rect" class="external-link" href="https://issues.apache.org/jira/browse/TAP5-2070">Issue TAP5-2070</a>.</p></div></div></div>
+</pre>
+</div></div><p>The end-result, in when <em>not</em> in production mode, looks like this:</p><p><span class="confluence-embedded-file-wrapper image-center-wrapper confluence-embedded-manual-size"><img class="confluence-embedded-image confluence-content-image-border image-center" width="500" src="error-page-recipe.data/Resource_not_found_.png"></span></p><div class="confluence-information-macro confluence-information-macro-information"><span class="aui-icon aui-icon-small aui-iconfont-info confluence-information-macro-icon"></span><div class="confluence-information-macro-body"><p>An issue with an application that has a root Index page is that any invalid path, which would normally generate a 404 error, is instead routed to the Index page (because the invalid path looks like page's activation context). See <a shape="rect" class="external-link" href="https://issues.apache.org/jira/browse/TAP5-2070">Issue TAP5-2070</a>.</p></div></div></div>
 </div>
 
 <div class="clearer"></div>

Modified: websites/production/tapestry/content/exploring-the-project.html
==============================================================================
--- websites/production/tapestry/content/exploring-the-project.html (original)
+++ websites/production/tapestry/content/exploring-the-project.html Sun Jul 19 21:21:27 2015
@@ -27,6 +27,16 @@
   </title>
   <link type="text/css" rel="stylesheet" href="/resources/space.css">
 
+    <link href='/resources/highlighter/styles/shCoreCXF.css' rel='stylesheet' type='text/css' />
+  <link href='/resources/highlighter/styles/shThemeCXF.css' rel='stylesheet' type='text/css' />
+  <script src='/resources/highlighter/scripts/shCore.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushJava.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushXml.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushPlain.js' type='text/javascript'></script>
+  <script type="text/javascript">
+  SyntaxHighlighter.defaults['toolbar'] = false;
+  SyntaxHighlighter.all();
+  </script>
 
   <link href="/styles/style.css" rel="stylesheet" type="text/css"/>
 
@@ -57,19 +67,11 @@
   </div>
 
 <div id="content">
-<div id="ConfluenceContent"><style type="text/css">/*<![CDATA[*/
-table.ScrollbarTable  {border: none;padding: 3px;width: 100%;padding: 3px;margin: 0px;background-color: #f0f0f0}
-table.ScrollbarTable td.ScrollbarPrevIcon {text-align: center;width: 16px;border: none;}
-table.ScrollbarTable td.ScrollbarPrevName {text-align: left;border: none;}
-table.ScrollbarTable td.ScrollbarParent {text-align: center;border: none;}
-table.ScrollbarTable td.ScrollbarNextName {text-align: right;border: none;}
-table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width: 16px;border: none;}
-
-/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="creating-the-skeleton-application.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="creating-the-skeleton-application.html">Creating The Skeleton Application</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="tapestry-tutorial.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="tapestry-tutorial.html">Tapestry Tutorial</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="implementing-the-hi-lo-guessing-game.html">Implementing the Hi-Lo Guessing Game</a></td><td col
 span="1" rowspan="1" class="ScrollbarNextIcon"><a shape="rect" href="implementing-the-hi-lo-guessing-game.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div><p>The layout of the project follows the sensible standards promoted by Maven:</p><ul><li>Java source files under <code>src/main/java</code></li><li>Web application files under <code>src/main/webapp</code> (including <code>src/main/webapp/WEB-INF</code>)</li><li>Java test sources under <code>src/test/java</code></li><li>Non-code resources (including Tapestry page and component templates) under <code>src/main/resources</code> and <code>src/test/resources</code></li></ul><p>Let's look at what Maven has created from the archetype, starting with the web.xml configuration file:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>src/main/webapp/WEB-
 INF/web.xml</b></div><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
+<div id="ConfluenceContent"><p>The layout of the project follows the sensible standards promoted by Maven:</p><ul><li>Java source files under <code>src/main/java</code></li><li>Web application files under <code>src/main/webapp</code> (including <code>src/main/webapp/WEB-INF</code>)</li><li>Java test sources under <code>src/test/java</code></li><li>Non-code resources (including Tapestry page and component templates) under <code>src/main/resources</code> and <code>src/test/resources</code></li></ul><p>Let's look at what Maven has created from the archetype, starting with the web.xml configuration file:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>src/main/webapp/WEB-INF/web.xml</b></div><div class="codeContent panelContent pdl">
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">&lt;?xml version="1.0" encoding="UTF-8"?&gt;
 &lt;!DOCTYPE web-app
-        PUBLIC &quot;-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN&quot;
-        &quot;http://java.sun.com/dtd/web-app_2_3.dtd&quot;&gt;
+        PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
+        "http://java.sun.com/dtd/web-app_2_3.dtd"&gt;
 &lt;web-app&gt;
     &lt;display-name&gt;tutorial1 Tapestry 5 Application&lt;/display-name&gt;
     &lt;context-param&gt;
@@ -104,9 +106,9 @@ of where to look for pages, components a
         &lt;url-pattern&gt;/*&lt;/url-pattern&gt;
     &lt;/filter-mapping&gt;
 &lt;/web-app&gt;
-]]></script>
+</pre>
 </div></div><p>This is short and sweet: you can see that the package name you provided earlier shows up as the <code>tapestry.app-package</code> context parameter; the TapestryFilter instance will use this information to locate the Java classes for pages and components.</p><p>Tapestry operates as a <em>servlet filter</em> rather than as a traditional <em>servlet</em>. In this way, Tapestry has a chance to intercept all incoming requests, to determine which ones apply to Tapestry pages (or other resources). The net effect is that you don't have to maintain any additional configuration for Tapestry to operate, regardless of how many pages or components you add to your application.</p><p>Much of the rest of web.xml is configuration to match Tapestry execution modes against module classes. An execution mode defines how the application is being run: the default execution mode is "production", but the web.xml defines two additional modes: "development" and "qa" (for "Quality Assurance"). 
 The module classes indicated will be loaded for those execution modes, and can change the configuration of the application is various ways. We'll come back to execution modes and module classes later in the tutorial.</p><p>Tapestry pages minimally consist of an ordinary Java class plus a component template file.</p><p>In the root of your web application, a page named "Index" will be used for any request that specifies no additional path after the context name.</p><h1 id="ExploringtheProject-IndexJavaClass">Index Java Class</h1><p>Tapestry has very specific rules for where page classes go. Tapestry adds a sub-package, "pages", to the root application package ("com.example.tutorial"); the Java classes for pages goes there. Thus the full Java class name is com.example.tutorial.pages.Index.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>src/main/java/com/example/tutorial/pages/Index.java</b></div><di
 v class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[package com.example.tutorial.pages;
+<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">package com.example.tutorial.pages;
 
 import java.util.Date;
 import org.apache.tapestry5.annotations.*;
@@ -142,7 +144,7 @@ public class Index
 
     void onActionFromIncrement()
     {
-        alertManager.info(&quot;Increment clicked&quot;);
+        alertManager.info("Increment clicked");
 
         clickCount++;
     }
@@ -151,17 +153,17 @@ public class Index
     {
         clickCount++;
 
-        alertManager.info(&quot;Increment (via Ajax) clicked&quot;);
+        alertManager.info("Increment (via Ajax) clicked");
 
         return zone;
     }
 }
-]]></script>
+</pre>
 </div></div><p>There's a bit going on in this listing, as the Index page attempts to demonstrate a bunch of different ideas in Tapestry. Even so, the class is essentially pretty simple: Tapestry pages and components have no base classes to extend, no interfaces to implement, and are just a very pure POJO (Plain Old Java Object) ... with some special naming conventions and annotations for fields and methods.</p><p>You do have to meet the Tapestry framework partway:</p><ul><li>You need to put the Java class in the expected package, here com.example.tutorial.pages</li><li>The class must be public</li><li>You need to make sure there's a public, no-arguments constructor (here, the Java compiler has silently provided one for us)</li><li>All non-static fields must be <strong>private</strong></li></ul><p>As we saw when running the application, the page displays the current date and time, as well as a couple of extra links. The <code>currentTime</code> property is where that value comes from
 ; shortly we'll see how that value is referenced in the template, so it can be extracted from the page and output.</p><p>Tapestry always matches a page class to a template; neither is functional without the other. In fact, components within a page are treated the same way (except that components do not always have templates).</p><p>You will often hear about the <a shape="rect" class="external-link" href="http://en.wikipedia.org/wiki/Model_view_controller" >Model-View-Controller pattern</a> (MVC). In Tapestry, the page class acts as both the Model (the source of data) and the controller (the logic that responds to user interaction). The template is the View in MVC. As a model, the page exposes JavaBeans properties that can be referenced in the template.</p><p>Let's look at how the component template builds on the Java class to provide the full user interface.</p><h1 id="ExploringtheProject-ComponentTemplate">Component Template</h1><p>Tapestry pages are the combination of a POJO Java 
 class with a Tapestry component template. The template has the same name as the Java class, but has the extension <code>.tml</code>. Since the Java class here is com.example.tutorial.pages.Index, the template file will be located at src/main/resource/com/example/tutorial/pages/Index.tml. Ultimately, both the Java class and the component template file will be stored in the same folder within the deployed WAR file.</p><p>Tapestry component templates are well-formed XML documents. This means that you can use any available XML editor. Templates may even have a DOCTYPE or an XML schema to validate the structure of the template page.</p><p><em>Note that Tapestry parses component templates using a non-validating parser; it only checks for well-formedness: proper syntax, balanced elements, attribute values are quoted, and so forth. It is reasonable for your build process to perform some kind of template validation, but Tapestry accepts the template as-is, as long as it parses cleanly.</em><
 /p><p>For the most part, a Tapestry component template looks like ordinary XHTML:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>src/main/resources/com/example/tutorial/pages/Index.tml</b></div><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[&lt;html t:type=&quot;layout&quot; title=&quot;tutorial1 Index&quot;
-      t:sidebarTitle=&quot;Framework Version&quot;
-      xmlns:t=&quot;http://tapestry.apache.org/schema/tapestry_5_3.xsd&quot;
-      xmlns:p=&quot;tapestry:parameter&quot;&gt;
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">&lt;html t:type="layout" title="tutorial1 Index"
+      t:sidebarTitle="Framework Version"
+      xmlns:t="http://tapestry.apache.org/schema/tapestry_5_3.xsd"
+      xmlns:p="tapestry:parameter"&gt;
         &lt;!-- Most of the page content, including &lt;head&gt;, &lt;body&gt;, etc. tags, comes from Layout.tml --&gt;
 
     &lt;p&gt;${message:greeting}&lt;/p&gt;
@@ -169,18 +171,18 @@ public class Index
     &lt;p&gt;The current time is: &lt;strong&gt;${currentTime}&lt;/strong&gt;&lt;/p&gt;
 
     &lt;!-- A Zone is a component that can be updated in place, triggered by other components. --&gt;
-    &lt;t:zone t:id=&quot;zone&quot;&gt;
+    &lt;t:zone t:id="zone"&gt;
         &lt;p&gt;
             You have clicked the link &lt;strong&gt;${clickCount}&lt;/strong&gt; times.
         &lt;/p&gt;
 
         &lt;p&gt;
             [
-            &lt;t:actionlink t:id=&quot;increment&quot;&gt;increment&lt;/t:actionlink&gt;
+            &lt;t:actionlink t:id="increment"&gt;increment&lt;/t:actionlink&gt;
             ]
             &amp;nbsp;
             [
-            &lt;t:actionlink t:id=&quot;incrementAjax&quot; zone=&quot;^&quot;&gt;increment (via Ajax)&lt;/t:actionlink&gt;
+            &lt;t:actionlink t:id="incrementAjax" zone="^"&gt;increment (via Ajax)&lt;/t:actionlink&gt;
             ]
         &lt;/p&gt;
 
@@ -194,73 +196,65 @@ public class Index
 
         &lt;p&gt;
             [
-            &lt;t:pagelink page=&quot;Index&quot;&gt;refresh page&lt;/t:pagelink&gt;
+            &lt;t:pagelink page="Index"&gt;refresh page&lt;/t:pagelink&gt;
             ]
         &lt;/p&gt;
     &lt;/p:sidebar&gt;
 
 &lt;/html&gt;
-]]></script>
+</pre>
 </div></div><div class="confluence-information-macro confluence-information-macro-tip"><span class="aui-icon aui-icon-small aui-iconfont-approve confluence-information-macro-icon"></span><div class="confluence-information-macro-body"><p>You do have to name your component template file, Index.tml, with the <strong>exact same case</strong> as the component class name, Index. If you get the case wrong, it may work on some operating systems (such as Mac OS X, Windows) and not on others (Linux, and most others). This can be really vexing, as it is common to develop on Windows and deploy on Linux or Solaris, so be careful about case in this one area.</p></div></div><p>The goal in Tapestry is for component templates, such as Index.tml, to look as much as possible like ordinary, static HTML files. (By static, we mean unchanging, as opposed to a dynamically generated Tapestry page.)</p><p>In fact, the expectation is that in many cases, the templates will start as static HTML files, created b
 y a web developer, and then be <em>instrumented</em> to act as live Tapestry pages.</p><p>Tapestry hides non-standard elements and attributes inside XML namespaces. By convention, the prefix "t:" is used for the primary namespace, but that is not a requirement, any prefix you want to use is fine.</p><p>This short template demonstrates quite a few features of Tapestry.</p><div class="confluence-information-macro confluence-information-macro-warning"><span class="aui-icon aui-icon-small aui-iconfont-error confluence-information-macro-icon"></span><div class="confluence-information-macro-body"><p>Part of the concept of the quickstart archetype is to demonstrate a bunch of different features, approaches, and common patterns used in Tapestry. So yes, we're hitting you with a lot all at once.</p></div></div><p>First of all, there are two XML namespaces defined:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[  xmlns:t=&quot;http://tapestry.apache.org/schema/tapestry_5_3.xsd&quot;
-  xmlns:p=&quot;tapestry:parameter&quot;
-]]></script>
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">  xmlns:t="http://tapestry.apache.org/schema/tapestry_5_3.xsd"
+  xmlns:p="tapestry:parameter"
+</pre>
 </div></div><p>The first namespace, "t:", it used to identify Tapestry-specific elements and attributes. Although there is an XSD (that is, a XML schema definition), it is incomplete (for reasons explained shortly).</p><p>The second namespace, "p:", is a way of marking a chunk of the template as a parameter passed into another component. We'll expand on that shortly.</p><p>A Tapestry component template consists mostly of standard XHTML that will pass down to the client web browser unchanged. The dynamic aspects of the template are represented by <em>components</em> and <em>expansions</em>.</p><h1 id="ExploringtheProject-ExpansionsinTemplates">Expansions in Templates</h1><p>Let's start with expansions. Expansions are an easy way of including some dynamic output when rendering the page. By default, an expansion refers to a JavaBeans property of the page:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[  &lt;p&gt;The current time is: ${currentTime}&lt;/p&gt;
-]]></script>
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">  &lt;p&gt;The current time is: ${currentTime}&lt;/p&gt;
+</pre>
 </div></div><div class="confluence-information-macro confluence-information-macro-tip"><span class="aui-icon aui-icon-small aui-iconfont-approve confluence-information-macro-icon"></span><div class="confluence-information-macro-body"><p>If you are coming to Tapestry 5 from Tapestry 4 or earlier, expansions are a concise replacement for the Insert component.</p></div></div><p>The value inside the curly braces is a <em>property expression</em>. Tapestry uses its own property expression language that is expressive, fast, and type-safe.</p><div class="confluence-information-macro confluence-information-macro-note"><span class="aui-icon aui-icon-small aui-iconfont-warning confluence-information-macro-icon"></span><div class="confluence-information-macro-body"><pre>Tapestry does NOT use reflection to implement property expressions.</pre></div></div><p>More advanced property expressions can traverse multiple properties (for example, <code>user.address.city</code>), or even invoke public me
 thods. Here the expansion simply reads the <code>currentTime</code> property of the page.</p><p>Tapestry follows the rules defined by Sun's JavaBeans specification: a property name of <code>currentTime</code> maps to two methods: <code>getCurrentTime()</code> and <code>setCurrentTime()</code>. If you omit one or the other of these methods, the property is either read only (as here), or write only. (Keep in mind that as far as JavaBeans properties go, it's the <em>methods</em> that count; the names of the instance variables, or even whether they exist, is immaterial.)</p><p>Tapestry does go one step further: it ignores case when matching properties inside the expansion to properties of the page. In the template we could say ${currenttime} or ${CurrentTime} or any variation, and Tapestry will <em>still</em> invoke the <code>getCurrentTime()</code> method.</p><p>Note that in Tapestry it is not necessary to configure what object holds the <code>currentTime</code> property; a template an
 d a page are always used in combination with each other; expressions are always rooted in the page instance, in this case, an instance of the Index class.</p><p>The Index.tml template includes a second expansion:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[    &lt;p&gt;${message:greeting}&lt;/p&gt;
-]]></script>
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">    &lt;p&gt;${message:greeting}&lt;/p&gt;
+</pre>
 </div></div><p>Here <code>greeting</code> is not a property of the page; its actually a localized message key. Every Tapestry page and component is allowed to have its own message catalog. (There's also a global message catalog, <em>which we'll describe later</em>.)</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>src/main/resources/com/example/tutorial/pages/Index.properties</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[greeting=Welcome to Tapestry 5!  We hope that this project template will get you going in style.
-]]></script>
+<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">greeting=Welcome to Tapestry 5!  We hope that this project template will get you going in style.
+</pre>
 </div></div><p>Message catalogs are useful for storing repeating strings outside of code or templates, though their primary purpose is related to localization of the application (which will be described in more detail in a later chapter). Messages that may be used across multiple pages can be stored in the application's global message catalog, src/main/webapp/WEB-INF/app.properties, instead.</p><p>This "message:" prefix is not some special case; there are actually quite a few of these <em>binding prefixes</em> built into Tapestry, each having a specific purpose. In fact, omitting a binding prefix in an expansion is exactly the same as using the "prop:" binding prefix, which means to treat the binding as a property expression.</p><p>Expansions are useful for extracting a piece of information and rendering it out to the client as a string, but the real heavy lifting of Tapestry occurs inside components.</p><h1 id="ExploringtheProject-ComponentsInsideTemplates">Components Inside Templa
 tes</h1><p>Components can be represented inside a component template in two ways:</p><ul><li>As an ordinary element, but with a t:type attribute to define the type of component.</li></ul><ul><li>As an element in the Tapestry namespace, in which case the element name determines the type.</li></ul><p>Here we've used an &lt;html&gt; element to represent the application's Layout component.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[&lt;html t:type=&quot;layout&quot; ...&gt; 
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">&lt;html t:type="layout" ...&gt; 
   ...
 &lt;/html&gt;
-]]></script>
+</pre>
 </div></div><p>But for the PageLink component, we've used an element in the Tapestry namespace:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[&lt;t:pagelink page=&quot;Index&quot;&gt;refresh page&lt;/t:pagelink&gt;
-]]></script>
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">&lt;t:pagelink page="Index"&gt;refresh page&lt;/t:pagelink&gt;
+</pre>
 </div></div><p>Which form you select is a matter of choice. In the vast majority of cases, they are exactly equivalent.</p><p>As elsewhere, case is ignored. Here the types ("layout" and "pagelink") were in all lower case; the actual class names are Layout and PageLink. Further, Tapestry "blends" the core library components in with the components defined by this application; thus type "layout" is mapped to application component class com.example.tutorial.components.Layout, but "pagelink" is mapped to Tapestry's built-in org.apache.tapestry5.corelib.components.PageLink class.</p><p>Tapestry components are configured using parameters; for each component, there is a set of parameters, each with a specific type and purpose. Some parameters are required, others are optional. Attributes of the element are used to <em>bind</em> parameters to specific literal values, or to page properties. Tapestry is flexible here as well; you can always place an attribute in the Tapestry namespace (using t
 he "t:" prefix), but in most cases, this is unnecessary.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[&lt;html t:type=&quot;layout&quot; title=&quot;tutorial1 Index&quot;
-      t:sidebarTitle=&quot;Framework Version&quot; ...
-]]></script>
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">&lt;html t:type="layout" title="tutorial1 Index"
+      t:sidebarTitle="Framework Version" ...
+</pre>
 </div></div><p>This binds two parameters, <code>title</code> and <code>sidebarTitle</code>, of the Layout component to the literal strings "tutorial1 Index" and "Current Time", respectively.</p><p>The Layout component will actually provide the bulk of the HTML ultimately sent to the browser; we'll look at its template in a later chapter. The point is, the page's template is integrated into the Layout component's template. The following diagram shows how parameters passed to the Layout component end up rendered in the final page:</p><p>    
 
 
 
 
-<span class="gliffy-container" id="gliffy-container-24346949-7952" data-fullwidth="913" data-ceoid="24188263" data-edit="${diagramEditLink.getLinkUrl()}" data-full="/confluence/plugins/gliffy/viewer.action?inline=false&amp;pageId=24188263&amp;attachmentId=24346949&amp;name=Templates%20and%20Parameters&amp;lastPage=%2Fpages%2Fviewpage.action%3FpageId%3D24188263" data-pageid="24188263" data-filename="Templates and Parameters">
+<span class="gliffy-container" id="gliffy-container-24346949-6407" data-fullwidth="913" data-ceoid="24188263" data-edit="${diagramEditLink.getLinkUrl()}" data-full="${diagramZoomLink.getLinkUrl()}" data-filename="Templates and Parameters">
 
-    <map id="gliffy-map-24346949-3370" name="gliffy-map-24346949-3370"></map>
+    <map id="gliffy-map-24346949-931" name="gliffy-map-24346949-931"></map>
 
-    <img class="gliffy-image gliffy-image-border" id="gliffy-image-24346949-7952" width="304" height="300" data-full-width="913" data-full-height="901" src="https://cwiki.apache.org/confluence/download/attachments/24188263/Templates%20and%20Parameters.png?version=2&amp;modificationDate=1371888025000&amp;api=v2" alt="Templates and Parameters" usemap="#gliffy-map-24346949-3370">
+    <img class="gliffy-image gliffy-image-border" id="gliffy-image-24346949-6407" width="304" height="300" data-full-width="913" data-full-height="901" src="https://cwiki.apache.org/confluence/download/attachments/24188263/Templates%20and%20Parameters.png?version=2&amp;modificationDate=1371888025000&amp;api=v2" alt="Templates and Parameters" usemap="#gliffy-map-24346949-931">
 
-    <map class="gliffy-dynamic" id="gliffy-dynamic-map-24346949-7952" name="gliffy-dynamic-map-24346949-7952"></map>
+    <map class="gliffy-dynamic" id="gliffy-dynamic-map-24346949-6407" name="gliffy-dynamic-map-24346949-6407"></map>
 </span>
 
 
 </p><p>The interesting point here (and this is an advanced concept in Tapestry, one we'll return to later) is that we can pass a chunk of the Index.tml template to the Layout component as the <code>sidebar</code> parameter. That's what the tapestry:parameter namespace (the "p:" prefix) is for; the element name is matched against a parameter of the component and the entire block of the template is passed into the Layout component ... which decides where, inside <em>its</em> template, that block gets rendered.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[&lt;t:pagelink page=&quot;Index&quot;&gt;refresh&lt;/t:pagelink&gt;
-]]></script>
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">&lt;t:pagelink page="Index"&gt;refresh&lt;/t:pagelink&gt;
+</pre>
 </div></div><p>This time, it's the <code>page</code> parameter of the PageLink component that is bound, to the literal value "Index" (which is the name of this page). This gets rendered as a URL that re-renders the page, which is how the current time gets updated. You can also create links to other pages in the application and, as we'll see in later chapters, attach additional information to the URL beyond just the page name.</p><h1 id="ExploringtheProject-AMagicTrick">A Magic Trick</h1><p>Now it's time for a magic trick. Edit Index.java and change the <code>getCurrentTime()</code> method to:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>Index.java (partial)</b></div><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[  public String getCurrentTime()
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">  public String getCurrentTime()
   {
-    return &quot;A great day to learn Tapestry&quot;;
+    return "A great day to learn Tapestry";
   }
-]]></script>
-</div></div><p>Make sure you save changes; then click the refresh link in the web browser:</p><p><span class="confluence-embedded-file-wrapper confluence-embedded-manual-size"><img class="confluence-embedded-image" width="700" src="exploring-the-project.data/app-live-reload.png" data-image-src="/confluence/download/attachments/24188263/app-live-reload.png?version=5&amp;modificationDate=1416707986000&amp;api=v2" data-unresolved-comment-count="0" data-linked-resource-id="24346955" data-linked-resource-version="5" data-linked-resource-type="attachment" data-linked-resource-default-alias="app-live-reload.png" data-base-url="https://cwiki.apache.org/confluence" data-linked-resource-content-type="image/png" data-linked-resource-container-id="24188263" data-linked-resource-container-version="31"></span></p><div class="navmenu" style="float:right; width:30%; background:white; margin:3px; padding:3px">
+</pre>
+</div></div><p>Make sure you save changes; then click the refresh link in the web browser:</p><p><span class="confluence-embedded-file-wrapper confluence-embedded-manual-size"><img class="confluence-embedded-image" width="700" src="exploring-the-project.data/app-live-reload.png"></span></p><div class="navmenu" style="float:right; width:30%; background:white; margin:3px; padding:3px">
 <div class="confluence-information-macro confluence-information-macro-note"><span class="aui-icon aui-icon-small aui-iconfont-warning confluence-information-macro-icon"></span><div class="confluence-information-macro-body">
-<p>If Live Class Reloading isn't working for you, check the Troubleshooting section at <a shape="rect" href="class-reloading.html" title="Class Reloading">Class Reloading</a>.</p></div></div></div><p>This is one of Tapestry's early <em>wow factor</em> features: changes to your component classes are picked up immediately (a feature we call Live Class Reloading). No restart. No re-deploy. Make the changes and see them <em>now</em>. Nothing should slow you down or get in the way of you getting your job done.</p><p>But ... what if you make a mistake? What if you got the name in the template wrong. Give it a try; in the template, change ${currentTime} to, say, ${currenTime}, and see what you get:</p><p><span class="confluence-embedded-file-wrapper confluence-embedded-manual-size"><img class="confluence-embedded-image" width="700" src="exploring-the-project.data/app-error-1.png" data-image-src="/confluence/download/attachments/24188263/app-error-1.png?version=3&amp;modificationDate=141670
 7595000&amp;api=v2" data-unresolved-comment-count="0" data-linked-resource-id="24346956" data-linked-resource-version="3" data-linked-resource-type="attachment" data-linked-resource-default-alias="app-error-1.png" data-base-url="https://cwiki.apache.org/confluence" data-linked-resource-content-type="image/png" data-linked-resource-container-id="24188263" data-linked-resource-container-version="31"></span></p><p>This is Tapestry's exception report page. It's quite detailed. It clearly identifies what Tapestry was doing, and relates the problem to a specific line in the template, which is shown in context. Tapestry always expands out the entire stack of exceptions, because it is so common for exceptions to be thrown, caught, and re-thrown inside other exceptions. In fact, if we scroll down just a little bit, we see more detail about this exception, plus a little bit of help:</p><p><span class="confluence-embedded-file-wrapper confluence-embedded-manual-size"><img class="confluence-emb
 edded-image" width="700" src="exploring-the-project.data/app-error-2.png" data-image-src="/confluence/download/attachments/24188263/app-error-2.png?version=4&amp;modificationDate=1416707595000&amp;api=v2" data-unresolved-comment-count="0" data-linked-resource-id="24346957" data-linked-resource-version="4" data-linked-resource-type="attachment" data-linked-resource-default-alias="app-error-2.png" data-base-url="https://cwiki.apache.org/confluence" data-linked-resource-content-type="image/png" data-linked-resource-container-id="24188263" data-linked-resource-container-version="31"></span></p><p>This is part of Tapestry's way: it not only spells out exactly what it was doing and what went wrong, but it even helps you find a solution; here it tells you the names of properties you could have used.</p><div class="confluence-information-macro confluence-information-macro-information"><span class="aui-icon aui-icon-small aui-iconfont-info confluence-information-macro-icon"></span><div class
 ="confluence-information-macro-body"><p>This level of detail reflects that the application has been configured to run in <em>development mode</em> instead of <em>production mode</em>. In production mode, the exception report would simply be the top level exception message. However, most production applications go further and customize how Tapestry handles and reports exceptions.</p></div></div><p>Tapestry displays the stack trace of the deepest exception, along with lots of details about the run-time environment: details about the current request, the HttpSession (if one exists), and even a detailed list of all JVM system properties. Scroll down to see all this information.</p><p>Next up: let's play a game...</p><hr><p>&#160;</p><style type="text/css">/*<![CDATA[*/
-table.ScrollbarTable  {border: none;padding: 3px;width: 100%;padding: 3px;margin: 0px;background-color: #f0f0f0}
-table.ScrollbarTable td.ScrollbarPrevIcon {text-align: center;width: 16px;border: none;}
-table.ScrollbarTable td.ScrollbarPrevName {text-align: left;border: none;}
-table.ScrollbarTable td.ScrollbarParent {text-align: center;border: none;}
-table.ScrollbarTable td.ScrollbarNextName {text-align: right;border: none;}
-table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width: 16px;border: none;}
-
-/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="creating-the-skeleton-application.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="creating-the-skeleton-application.html">Creating The Skeleton Application</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="tapestry-tutorial.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="tapestry-tutorial.html">Tapestry Tutorial</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="implementing-the-hi-lo-guessing-game.html">Implementing the Hi-Lo Guessing Game</a></td><td col
 span="1" rowspan="1" class="ScrollbarNextIcon"><a shape="rect" href="implementing-the-hi-lo-guessing-game.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div></div>
+<p>If Live Class Reloading isn't working for you, check the Troubleshooting section at <a shape="rect" href="class-reloading.html" title="Class Reloading">Class Reloading</a>.</p></div></div></div><p>This is one of Tapestry's early <em>wow factor</em> features: changes to your component classes are picked up immediately (a feature we call Live Class Reloading). No restart. No re-deploy. Make the changes and see them <em>now</em>. Nothing should slow you down or get in the way of you getting your job done.</p><p>But ... what if you make a mistake? What if you got the name in the template wrong. Give it a try; in the template, change ${currentTime} to, say, ${currenTime}, and see what you get:</p><p><span class="confluence-embedded-file-wrapper confluence-embedded-manual-size"><img class="confluence-embedded-image" width="700" src="exploring-the-project.data/app-error-1.png"></span></p><p>This is Tapestry's exception report page. It's quite detailed. It clearly identifies what Tapestr
 y was doing, and relates the problem to a specific line in the template, which is shown in context. Tapestry always expands out the entire stack of exceptions, because it is so common for exceptions to be thrown, caught, and re-thrown inside other exceptions. In fact, if we scroll down just a little bit, we see more detail about this exception, plus a little bit of help:</p><p><span class="confluence-embedded-file-wrapper confluence-embedded-manual-size"><img class="confluence-embedded-image" width="700" src="exploring-the-project.data/app-error-2.png"></span></p><p>This is part of Tapestry's way: it not only spells out exactly what it was doing and what went wrong, but it even helps you find a solution; here it tells you the names of properties you could have used.</p><div class="confluence-information-macro confluence-information-macro-information"><span class="aui-icon aui-icon-small aui-iconfont-info confluence-information-macro-icon"></span><div class="confluence-information-ma
 cro-body"><p>This level of detail reflects that the application has been configured to run in <em>development mode</em> instead of <em>production mode</em>. In production mode, the exception report would simply be the top level exception message. However, most production applications go further and customize how Tapestry handles and reports exceptions.</p></div></div><p>Tapestry displays the stack trace of the deepest exception, along with lots of details about the run-time environment: details about the current request, the HttpSession (if one exists), and even a detailed list of all JVM system properties. Scroll down to see all this information.</p><p>Next up: let's play a game...</p><hr><p>&#160;</p></div>
 </div>
 
 <div class="clearer"></div>

Modified: websites/production/tapestry/content/extending-the-if-component.html
==============================================================================
--- websites/production/tapestry/content/extending-the-if-component.html (original)
+++ websites/production/tapestry/content/extending-the-if-component.html Sun Jul 19 21:21:27 2015
@@ -27,6 +27,16 @@
   </title>
   <link type="text/css" rel="stylesheet" href="/resources/space.css">
 
+    <link href='/resources/highlighter/styles/shCoreCXF.css' rel='stylesheet' type='text/css' />
+  <link href='/resources/highlighter/styles/shThemeCXF.css' rel='stylesheet' type='text/css' />
+  <script src='/resources/highlighter/scripts/shCore.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushJava.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushXml.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushPlain.js' type='text/javascript'></script>
+  <script type="text/javascript">
+  SyntaxHighlighter.defaults['toolbar'] = false;
+  SyntaxHighlighter.all();
+  </script>
 
   <link href="/styles/style.css" rel="stylesheet" type="text/css"/>
 
@@ -57,16 +67,8 @@
   </div>
 
 <div id="content">
-<div id="ConfluenceContent"><style type="text/css">/*<![CDATA[*/
-table.ScrollbarTable  {border: none;padding: 3px;width: 100%;padding: 3px;margin: 0px;background-color: #f0f0f0}
-table.ScrollbarTable td.ScrollbarPrevIcon {text-align: center;width: 16px;border: none;}
-table.ScrollbarTable td.ScrollbarPrevName {text-align: left;border: none;}
-table.ScrollbarTable td.ScrollbarParent {text-align: center;border: none;}
-table.ScrollbarTable td.ScrollbarNextName {text-align: right;border: none;}
-table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width: 16px;border: none;}
-
-/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="enum-parameter-recipe.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="enum-parameter-recipe.html">Enum Parameter Recipe</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="cookbook.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="cookbook.html">Cookbook</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="meta-programming-page-content.html">Meta-Programming Page Content</a></td><td colspan="1" rowspan="1" class="ScrollbarNextIcon"><a shape="rect" href="meta-pro
 gramming-page-content.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div><h1 id="ExtendingtheIfComponent-ExtendingtheIfComponent">Extending the If Component</h1><p>The <a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/corelib/components/If.html">If</a> component can be made very flexible; its main parameter, <code>test</code>, does not <em>have</em> to be bound to a boolean value, it merely has to be bound to a value that can be <a shape="rect" href="type-coercion.html">coerced</a> to boolean.</p><p>For example, you may be working on an application that does a lot of <a shape="rect" class="external-link" href="http://lucene.apache.org/java/docs/index.html">Lucene</a> searches, and you represent the results as a SearchResult object:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader
  pdl" style="border-bottom-width: 1px;"><b>SearchResult.java</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public class SearchResult&lt;T&gt; {
+<div id="ConfluenceContent"><h1 id="ExtendingtheIfComponent-ExtendingtheIfComponent">Extending the If Component</h1><p>The <a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/corelib/components/If.html">If</a> component can be made very flexible; its main parameter, <code>test</code>, does not <em>have</em> to be bound to a boolean value, it merely has to be bound to a value that can be <a shape="rect" href="type-coercion.html">coerced</a> to boolean.</p><p>For example, you may be working on an application that does a lot of <a shape="rect" class="external-link" href="http://lucene.apache.org/java/docs/index.html">Lucene</a> searches, and you represent the results as a SearchResult object:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>SearchResult.java</b></div><div class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">public class SearchResult&lt;T&gt; {
   public final Class&lt;T&gt; itemType;
   public final List&lt;T&gt; items;
   public final int size;
@@ -88,16 +90,16 @@ table.ScrollbarTable td.ScrollbarNextIco
     return size == 0;
   }
 }
-]]></script>
+</pre>
 </div></div><p>In a SearchResult, the <code>size</code> property is the overall number of results from the search. The <code>items</code> list is a single "page" of those results to present to the user, consisting of items from <code>firstIndex</code> to <code>lastIndex</code> within the overall set.</p><p>In your templates, you have to check to see if the SearchResult exists, then see if it is empty, before you can get to the part that displays the content:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[&lt;t:if test=&quot;searchResult&quot;&gt;
-  &lt;t:if test=&quot;! searchResult.empty&quot;&gt;
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">&lt;t:if test="searchResult"&gt;
+  &lt;t:if test="! searchResult.empty"&gt;
     . . .
   &lt;/t:if&gt;
 &lt;/t:if&gt;
-]]></script>
+</pre>
 </div></div><p>The first test checks to see if <code>searchResult</code> is not null (null is treated as false). The second checks to see if the search result is empty.</p><p>What we'd like is for the test to look at the <code>searchResult</code> directly and treat an empty search result as false, and a non-empty search result as true. This is similar to what Tapestry already does for Collections.</p><p>This is just a matter of extending the TypeCoercer service:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>AppModule.java (partial)</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[public static void contributeTypeCoercer(Configuration&lt;CoercionTuple&gt; configuration) {
+<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">public static void contributeTypeCoercer(Configuration&lt;CoercionTuple&gt; configuration) {
 
   add(configuration, SearchResult.class, Boolean.class,
       new Coercion&lt;SearchResult, Boolean&gt;() {
@@ -114,12 +116,12 @@ private static &lt;S, T&gt; void add(Con
 
   configuration.add(tuple);
 }
-]]></script>
+</pre>
 </div></div><p>Inside this thicket of generics and brackets is the code that treats a SearchResult as a boolean: <code>return !input.isEmpty();</code>.</p><p>With this in place, the previous template can be simplified:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: xml; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[&lt;t:if test=&quot;searchResult&quot;&gt;
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">&lt;t:if test="searchResult"&gt;
   . . .
 &lt;/t:if&gt;
-]]></script>
+</pre>
 </div></div><p>The single test now implies that <code>searchResult</code> is not null and not empty.</p></div>
 </div>
 

Modified: websites/production/tapestry/content/forms-and-form-components-faq.html
==============================================================================
--- websites/production/tapestry/content/forms-and-form-components-faq.html (original)
+++ websites/production/tapestry/content/forms-and-form-components-faq.html Sun Jul 19 21:21:27 2015
@@ -27,6 +27,16 @@
   </title>
   <link type="text/css" rel="stylesheet" href="/resources/space.css">
 
+    <link href='/resources/highlighter/styles/shCoreCXF.css' rel='stylesheet' type='text/css' />
+  <link href='/resources/highlighter/styles/shThemeCXF.css' rel='stylesheet' type='text/css' />
+  <script src='/resources/highlighter/scripts/shCore.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushJava.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushXml.js' type='text/javascript'></script>
+  <script src='/resources/highlighter/scripts/shBrushPlain.js' type='text/javascript'></script>
+  <script type="text/javascript">
+  SyntaxHighlighter.defaults['toolbar'] = false;
+  SyntaxHighlighter.all();
+  </script>
 
   <link href="/styles/style.css" rel="stylesheet" type="text/css"/>
 
@@ -57,16 +67,8 @@
   </div>
 
 <div id="content">
-<div id="ConfluenceContent"><style type="text/css">/*<![CDATA[*/
-table.ScrollbarTable  {border: none;padding: 3px;width: 100%;padding: 3px;margin: 0px;background-color: #f0f0f0}
-table.ScrollbarTable td.ScrollbarPrevIcon {text-align: center;width: 16px;border: none;}
-table.ScrollbarTable td.ScrollbarPrevName {text-align: left;border: none;}
-table.ScrollbarTable td.ScrollbarParent {text-align: center;border: none;}
-table.ScrollbarTable td.ScrollbarNextName {text-align: right;border: none;}
-table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width: 16px;border: none;}
-
-/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="page-and-component-classes-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="page-and-component-classes-faq.html">Page And Component Classes FAQ</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="frequently-asked-questions.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="frequently-asked-questions.html">Frequently Asked Questions</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="beaneditform-faq.html">BeanEditForm FAQ</a></td><td colspan="1" rowspan="1" c
 lass="ScrollbarNextIcon"><a shape="rect" href="beaneditform-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div><h2 id="FormsandFormComponentsFAQ-FormsandFormComponents">Forms and Form Components</h2><p>Main article: <a shape="rect" href="forms-and-validation.html">Forms and Validation</a></p><h3 id="FormsandFormComponentsFAQ-Whatisthet:formdatahiddenfieldfor?">What is the <code>t:formdata</code> hidden field for?</h3><p>In Tapestry, rendering a form can be a complicated process; inside the body of the Form component are many of field components: TextField, Select, TextArea, and so forth. Each of these must pull data out of your data model and convert it to the string form used inside the client web browser. In addition, JavaScript to support client-side validation must be generated. This can be further complicated by the use of Loop and If components, or made really complicat
 ed by the use of Block (to render portions of other pages: this is what the BeanEditForm component does).</p><p>Along the way, the Form is generating unique form control names for each field component, as it renders.</p><p>When the client-side Form is submitted, an event is triggered on the server-side Form component. It now needs to locate each component, in turn, inform the component of its control name, and allow the component to read the corresponding query parameter. The component then converts the client-side string back into a server-side value and performs validations before updating the data model.</p><p>That's where <code>t:formdata</code> comes in. While components are rendering, they are using the FormSupport environmental object to record callbacks:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>FormSupport.java (partial)</b></div><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: true; theme: Default" type="syntaxhighlighter"><![CDATA[public interface FormSupport extends ClientElement
+<div id="ConfluenceContent"><h2 id="FormsandFormComponentsFAQ-FormsandFormComponents">Forms and Form Components</h2><p>Main article: <a shape="rect" href="forms-and-validation.html">Forms and Validation</a></p><h3 id="FormsandFormComponentsFAQ-Whatisthet:formdatahiddenfieldfor?">What is the <code>t:formdata</code> hidden field for?</h3><p>In Tapestry, rendering a form can be a complicated process; inside the body of the Form component are many of field components: TextField, Select, TextArea, and so forth. Each of these must pull data out of your data model and convert it to the string form used inside the client web browser. In addition, JavaScript to support client-side validation must be generated. This can be further complicated by the use of Loop and If components, or made really complicated by the use of Block (to render portions of other pages: this is what the BeanEditForm component does).</p><p>Along the way, the Form is generating unique form control names for each field c
 omponent, as it renders.</p><p>When the client-side Form is submitted, an event is triggered on the server-side Form component. It now needs to locate each component, in turn, inform the component of its control name, and allow the component to read the corresponding query parameter. The component then converts the client-side string back into a server-side value and performs validations before updating the data model.</p><p>That's where <code>t:formdata</code> comes in. While components are rendering, they are using the FormSupport environmental object to record callbacks:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeHeader panelHeader pdl" style="border-bottom-width: 1px;"><b>FormSupport.java (partial)</b></div><div class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: true; theme: Default" style="font-size:12px;">public interface FormSupport extends ClientElement
 {
     /**
      * Stores an action for execution during a later request.  If the action contains any mutable state, it should be in
@@ -77,39 +79,31 @@ table.ScrollbarTable td.ScrollbarNextIco
     /**
      * As with {@link #store(Object, org.apache.tapestry5.ComponentAction)}}, but the action is also invoked
      * immediately. This is useful for defining an action that should occur symmetrically in both the render request and
-     * the form submission&#39;s event request.
+     * the form submission's event request.
      *
      * @param component component against which to trigger the action
      * @param action    the action that will be triggered (and passed the component)
      */
     &lt;T&gt; void storeAndExecute(T component, ComponentAction&lt;T&gt; action);
-]]></script>
+</pre>
 </div></div><p>The <code>ComponentAction</code> objects are the callbacks. <code>t:formdata</code> is simply an object stream of these callbacks, compressed and encoded in Base64. When using Ajax, you may see multiple <code>t:formdata</code> hidden fields (they are processed one after another).</p><h3 id="FormsandFormComponentsFAQ-HowdoIchangethelabelforafieldonthefly?">How do I change the label for a field on the fly?</h3><p>Tapestry tries to be smart about generating the label string for a field. It has some smart default logic, first checking for the <em>component-id</em><code>-label</code> in the container's message catalog, then ultimately converting the component's id into a user-presentable label.</p><p>You can override the label in two ways:</p><p>First, you can supply a body to the <code>Label</code> component:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: true; theme: Default" type="syntaxhighlighter"><![CDATA[  &lt;t:label for=&quot;username&quot;&gt;${usernameLabel}&lt;/t:label&gt;
-  &lt;t:textfield t:id=&quot;username&quot;/&gt;
-]]></script>
+<pre class="brush: java; gutter: true; theme: Default" style="font-size:12px;">  &lt;t:label for="username"&gt;${usernameLabel}&lt;/t:label&gt;
+  &lt;t:textfield t:id="username"/&gt;
+</pre>
 </div></div><p>Here, the component class must provide a <code>usernameLabel</code> property. That property becomes the text of the label. An implementation of the property might look something like:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: true; theme: Default" type="syntaxhighlighter"><![CDATA[  public String getUsernameLabel()
+<pre class="brush: java; gutter: true; theme: Default" style="font-size:12px;">  public String getUsernameLabel()
   {
-    return systemPreferences.useEmailAddressForUserName() ? &quot;Email address&quot; : &quot;User name&quot;;
+    return systemPreferences.useEmailAddressForUserName() ? "Email address" : "User name";
   }
-]]></script>
+</pre>
 </div></div><p>However, if there are any validations on the field, the error message will include the default label (as discussed above).</p><p>To uniformly update the label both on the page, and in any validation messages, bind the TextField's <code>label</code> parameter:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: true; theme: Default" type="syntaxhighlighter"><![CDATA[  &lt;t:label for=&quot;username&quot;/&gt;
-  &lt;t:textfield t:id=&quot;username&quot; label=&quot;prop:usernameLabel&quot;/&gt;
-]]></script>
+<pre class="brush: java; gutter: true; theme: Default" style="font-size:12px;">  &lt;t:label for="username"/&gt;
+  &lt;t:textfield t:id="username" label="prop:usernameLabel"/&gt;
+</pre>
 </div></div><p>The "prop:" prefix identifies that "usernameLabel" is to be interpreted as a property expression (normally, the binding for the <code>label</code> parameter is interpreted as a string literal). The Label component gets the text it displays from the TextField component, and the TextField component uses the same text when generating server-side and client-side validation messages.</p><h3 id="FormsandFormComponentsFAQ-Tapestryfocusesonthewrongfieldinmyform,howdoIfixthat?">Tapestry focuses on the wrong field in my form, how do I fix that?</h3><p>Tapestry normally figures out the correct field in your form to initially receive focus; this is based on assigning a <a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/FieldFocusPriority.html">FieldFocusPriority</a> to each field as it renders, which works out to the following logic:</p><ul><li>The first field which has an error</li><li>Or, the first field which is required
 </li><li>Or, the first field</li></ul><p>Occasionally, due a wide range of factors beyond Tapestry's control, it's selection will not be quite what you want, and it is necessary to supply an override. The information is tracked inside the <a shape="rect" class="external-link" href="http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/services/javascript/JavaScriptSupport.html">JavaScriptSupport</a> environmental. It's just a matter of injecting the component so that you can determine its client id, then informing JavaScriptSupport about your override.</p><p>Here's an example</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="brush: java; gutter: false; theme: Default" type="syntaxhighlighter"><![CDATA[  &lt;t:textfield t:id=&quot;email&quot; t:mixins=&quot;OverrideFieldFocus&quot; .../&gt;
-]]></script>
-</div></div><p>The <a shape="rect" class="external-link" href="http://tapestry.apache.org/5.4/apidocs/org/apache/tapestry5/corelib/mixins/OverrideFieldFocus.html">OverrideFieldFocus</a> mixin forces the email field to be the focus field, regardless.</p><style type="text/css">/*<![CDATA[*/
-table.ScrollbarTable  {border: none;padding: 3px;width: 100%;padding: 3px;margin: 0px;background-color: #f0f0f0}
-table.ScrollbarTable td.ScrollbarPrevIcon {text-align: center;width: 16px;border: none;}
-table.ScrollbarTable td.ScrollbarPrevName {text-align: left;border: none;}
-table.ScrollbarTable td.ScrollbarParent {text-align: center;border: none;}
-table.ScrollbarTable td.ScrollbarNextName {text-align: right;border: none;}
-table.ScrollbarTable td.ScrollbarNextIcon {text-align: center;width: 16px;border: none;}
-
-/*]]>*/</style><div class="Scrollbar"><table class="ScrollbarTable"><tr><td colspan="1" rowspan="1" class="ScrollbarPrevIcon"><a shape="rect" href="page-and-component-classes-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/back_16.gif" width="16" height="16"></a></td><td colspan="1" rowspan="1" class="ScrollbarPrevName" width="33%"><a shape="rect" href="page-and-component-classes-faq.html">Page And Component Classes FAQ</a>&#160;</td><td colspan="1" rowspan="1" class="ScrollbarParent" width="33%"><sup><a shape="rect" href="frequently-asked-questions.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/up_16.gif" width="8" height="8"></a></sup><a shape="rect" href="frequently-asked-questions.html">Frequently Asked Questions</a></td><td colspan="1" rowspan="1" class="ScrollbarNextName" width="33%">&#160;<a shape="rect" href="beaneditform-faq.html">BeanEditForm FAQ</a></td><td colspan="1" rowspan="1" c
 lass="ScrollbarNextIcon"><a shape="rect" href="beaneditform-faq.html"><img align="middle" border="0" src="https://cwiki.apache.org/confluence/images/icons/forwd_16.gif" width="16" height="16"></a></td></tr></table></div></div>
+<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">  &lt;t:textfield t:id="email" t:mixins="OverrideFieldFocus" .../&gt;
+</pre>
+</div></div><p>The <a shape="rect" class="external-link" href="http://tapestry.apache.org/5.4/apidocs/org/apache/tapestry5/corelib/mixins/OverrideFieldFocus.html">OverrideFieldFocus</a> mixin forces the email field to be the focus field, regardless.</p></div>
 </div>
 
 <div class="clearer"></div>



Mime
View raw message