Title: [waffle-scm] [629] trunk/examples/freemarker-example/src/main/webapp: Renamed freemarker-example FTL templates to have .ftl extension in order to facilitate FTL IDE support.

Diff

Modified: trunk/examples/freemarker-example/src/main/webapp/WEB-INF/decorators.xml (628 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/WEB-INF/decorators.xml	2008-04-19 15:53:00 UTC (rev 628)
+++ trunk/examples/freemarker-example/src/main/webapp/WEB-INF/decorators.xml	2008-04-19 16:04:14 UTC (rev 629)
@@ -1,7 +1,7 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
+<?xml version="1.0" encoding="UTF-8"?>
 
 <decorators defaultdir="/">
-    <decorator name="main" page="siteDecorator.htm">
+    <decorator name="main" page="layout.ftl">
         <pattern>/*</pattern>
     </decorator>
 </decorators>
\ No newline at end of file

Modified: trunk/examples/freemarker-example/src/main/webapp/WEB-INF/web.xml (628 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/WEB-INF/web.xml	2008-04-19 15:53:00 UTC (rev 628)
+++ trunk/examples/freemarker-example/src/main/webapp/WEB-INF/web.xml	2008-04-19 16:04:14 UTC (rev 629)
@@ -56,7 +56,7 @@
     <servlet-class>org.codehaus.waffle.servlet.WaffleServlet</servlet-class>
     <init-param>
       <param-name>view.suffix</param-name>
-      <param-value>.htm</param-value>
+      <param-value>.ftl</param-value>
     </init-param>
     <load-on-startup>1</load-on-startup>
   </servlet>
@@ -82,12 +82,12 @@
 
   <servlet-mapping>
     <servlet-name>sitemesh-freemarker</servlet-name>
-    <url-pattern>*.htm</url-pattern>
+    <url-pattern>*.ftl</url-pattern>
   </servlet-mapping>
 
   <!-- Welcome files -->
   <welcome-file-list>
-    <welcome-file>index.html</welcome-file>
+    <welcome-file>index.ftl</welcome-file>
   </welcome-file-list>
 
   <!-- Security -->

Copied: trunk/examples/freemarker-example/src/main/webapp/fielderrors.ftl (from rev 618, trunk/examples/freemarker-example/src/main/webapp/fielderrors.htm) (0 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/fielderrors.ftl	                        (rev 0)
+++ trunk/examples/freemarker-example/src/main/webapp/fielderrors.ftl	2008-04-19 16:04:14 UTC (rev 629)
@@ -0,0 +1,6 @@
+<#list errors.allErrorMessages as error>
+    <script type="text/_javascript_">
+        $('${error.name}').value = '${error.value}';
+        $('${error.name}').style.border = 'solid red 2px';
+    </script>
+</#list>
\ No newline at end of file

Deleted: trunk/examples/freemarker-example/src/main/webapp/fielderrors.htm (628 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/fielderrors.htm	2008-04-19 15:53:00 UTC (rev 628)
+++ trunk/examples/freemarker-example/src/main/webapp/fielderrors.htm	2008-04-19 16:04:14 UTC (rev 629)
@@ -1,6 +0,0 @@
-<#list errors.allErrorMessages as error>
-    <script type="text/_javascript_">
-        $('${error.name}').value = '${error.value}';
-        $('${error.name}').style.border = 'solid red 2px';
-    </script>
-</#list>
\ No newline at end of file

Copied: trunk/examples/freemarker-example/src/main/webapp/index.ftl (from rev 618, trunk/examples/freemarker-example/src/main/webapp/index.html) (0 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/index.ftl	                        (rev 0)
+++ trunk/examples/freemarker-example/src/main/webapp/index.ftl	2008-04-19 16:04:14 UTC (rev 629)
@@ -0,0 +1,15 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
+        "http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+  <title>Waffle: FreeMarker example</title>
+    <style type="text/css" title="currentStyle" media="screen">
+        @import "stylesheets/style.css";
+    </style>
+</head>
+<body>
+    <h1>Waffle example with Freemarker</h1>
+    <p>Welcome to the Waffle Freemarker/Sitemesh example.  Click on the link below to go to the single controller for this example</p>
+    <a href="" Maintenance</a>
+</body>
+</html>
\ No newline at end of file

Deleted: trunk/examples/freemarker-example/src/main/webapp/index.html (628 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/index.html	2008-04-19 15:53:00 UTC (rev 628)
+++ trunk/examples/freemarker-example/src/main/webapp/index.html	2008-04-19 16:04:14 UTC (rev 629)
@@ -1,15 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-        "http://www.w3.org/TR/html4/loose.dtd">
-<html>
-<head>
-  <title>Waffle: FreeMarker example</title>
-    <style type="text/css" title="currentStyle" media="screen">
-        @import "stylesheets/style.css";
-    </style>
-</head>
-<body>
-    <h1>Waffle example with Freemarker</h1>
-    <p>Welcome to the Waffle Freemarker/Sitemesh example.  Click on the link below to go to the single controller for this example</p>
-    <a href="" Maintenance</a>
-</body>
-</html>
\ No newline at end of file

Copied: trunk/examples/freemarker-example/src/main/webapp/layout.ftl (from rev 618, trunk/examples/freemarker-example/src/main/webapp/siteDecorator.htm) (0 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/layout.ftl	                        (rev 0)
+++ trunk/examples/freemarker-example/src/main/webapp/layout.ftl	2008-04-19 16:04:14 UTC (rev 629)
@@ -0,0 +1,15 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
+        "http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+  <title>${title}</title>
+  ${head}
+</head>
+<body>
+  ~ Standard Header ~
+  <hr/>
+    ${body}
+  <hr/>
+  ~ Decorator Added Footer ~
+</body>
+</html>
\ No newline at end of file

Added: trunk/examples/freemarker-example/src/main/webapp/people/editperson.ftl (0 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/people/editperson.ftl	                        (rev 0)
+++ trunk/examples/freemarker-example/src/main/webapp/people/editperson.ftl	2008-04-19 16:04:14 UTC (rev 629)
@@ -0,0 +1,60 @@
+<#import "/ftl/waffle/form.ftl" as w>
+<#import "/ftl/waffle/validation.ftl" as v>
+<div class="editContainer" xmlns="http://www.w3.org/1999/xhtml">
+
+    <h3>Edit Person</h3>
+
+    <@v.errorsAsDiv errors />
+    
+    <div class="fieldRow">
+        <label for=""
+        <@w.text "person.id" "${person.id}" "readonly='true' disabled='true'"/>
+        <br style="clear:both"/>
+    </div>
+    <div class="fieldRow">
+        <label for="" Name:</label>
+        <@w.text "person.firstName" "${person.firstName}"/>
+        <br style="clear:both"/>
+    </div>
+    <div class="fieldRow">
+        <label for="" Name:</label>
+        <@w.text "person.lastName" "${person.lastName}"/>
+        <br style="clear:both"/>
+    </div>
+    <div class="fieldRow">
+        <label for=""
+        <@w.text "person.email" "${person.email}"/>
+        <br style="clear:both"/>
+    </div>
+    <div class="fieldRow">
+        <label for="" Of Birth:</label>
+        <#if person.dateOfBirth??>
+            <@w.text "person.dateOfBirth" "${person.dateOfBirth?string('dd/MM/yyyy')}"/>
+        <#else>
+            <@w.text "person.dateOfBirth" ""/>
+        </#if> 
+        <br style="clear:both"/>
+    </div>
+    <div class="fieldRow">
+        <label for=""
+        <@w.selectMultiple "person.skills" controller.getSkills() person.getSkills() "size='5'"/>
+        <br style="clear:both"/>
+    </div>
+    <div class="fieldRow">
+        <label for=""
+        <@w.textAsCSV "person.levels" person.getLevels()![] /> 
+        <br style="clear:both"/>
+    </div>
+    <div class="fieldRow">
+        <label for=""
+        <@w.textAsCSV "person.grades" person.getGrades()![] /> 
+        <br style="clear:both"/>
+    </div>
+
+    <br/>
+    <a href="" |
+    <a href=""
+
+    <#include "../fielderrors.ftl" parse="true">
+
+</div>
\ No newline at end of file

Deleted: trunk/examples/freemarker-example/src/main/webapp/people/editperson.htm (628 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/people/editperson.htm	2008-04-19 15:53:00 UTC (rev 628)
+++ trunk/examples/freemarker-example/src/main/webapp/people/editperson.htm	2008-04-19 16:04:14 UTC (rev 629)
@@ -1,60 +0,0 @@
-<#import "/ftl/waffle/form.ftl" as w>
-<#import "/ftl/waffle/validation.ftl" as v>
-<div class="editContainer" xmlns="http://www.w3.org/1999/xhtml">
-
-    <h3>Edit Person</h3>
-
-    <@v.errorsAsDiv errors />
-    
-    <div class="fieldRow">
-        <label for=""
-        <@w.text "person.id" "${person.id}" "readonly='true' disabled='true'"/>
-        <br style="clear:both"/>
-    </div>
-    <div class="fieldRow">
-        <label for="" Name:</label>
-        <@w.text "person.firstName" "${person.firstName}"/>
-        <br style="clear:both"/>
-    </div>
-    <div class="fieldRow">
-        <label for="" Name:</label>
-        <@w.text "person.lastName" "${person.lastName}"/>
-        <br style="clear:both"/>
-    </div>
-    <div class="fieldRow">
-        <label for=""
-        <@w.text "person.email" "${person.email}"/>
-        <br style="clear:both"/>
-    </div>
-    <div class="fieldRow">
-        <label for="" Of Birth:</label>
-        <#if person.dateOfBirth??>
-            <@w.text "person.dateOfBirth" "${person.dateOfBirth?string('dd/MM/yyyy')}"/>
-        <#else>
-            <@w.text "person.dateOfBirth" ""/>
-        </#if> 
-        <br style="clear:both"/>
-    </div>
-    <div class="fieldRow">
-        <label for=""
-        <@w.selectMultiple "person.skills" controller.getSkills() person.getSkills() "size='5'"/>
-        <br style="clear:both"/>
-    </div>
-    <div class="fieldRow">
-        <label for=""
-        <@w.textAsCSV "person.levels" person.getLevels()![] /> 
-        <br style="clear:both"/>
-    </div>
-    <div class="fieldRow">
-        <label for=""
-        <@w.textAsCSV "person.grades" person.getGrades()![] /> 
-        <br style="clear:both"/>
-    </div>
-
-    <br/>
-    <a href="" |
-    <a href=""
-
-    <#include "../fielderrors.htm" parse="true">
-
-</div>
\ No newline at end of file

Copied: trunk/examples/freemarker-example/src/main/webapp/people/person.ftl (from rev 628, trunk/examples/freemarker-example/src/main/webapp/people/person.htm) (0 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/people/person.ftl	                        (rev 0)
+++ trunk/examples/freemarker-example/src/main/webapp/people/person.ftl	2008-04-19 16:04:14 UTC (rev 629)
@@ -0,0 +1,71 @@
+<#import "/ftl/waffle/form.ftl" as w>
+<?xml version="1.0" encoding="UTF-8"?>
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+<head>
+    <title>Select a person</title>
+    <style type="text/css" title="currentStyle" media="screen">
+        @import "../stylesheets/style.css";
+    </style>
+    <script src="" type="text/_javascript_">
+        // keep this space
+    </script>
+    <script src="" type="text/_javascript_">
+        // keep this space
+    </script>
+</head>
+
+<body>
+<form action="" method="post">
+
+    <h3>Waffle example: Select Person</h3>
+
+    <table>
+        <tr>
+            <th>Id</th>
+            <th>First Name</th>
+            <th>Last Name</th>
+            <th>Email</th>
+            <th>Date of Birth</th>
+            <th>Skills</th>
+            <th>Select</th>
+        </tr>
+        <#list people as person>
+            <tr class="odd">
+                <td>
+                    <a href=""
+                </td>
+                <td>${person.firstName}</td>
+                <td>${person.lastName}</td>
+                <td>${person.email}</td>
+                <td><#if person.dateOfBirth??>${person.dateOfBirth?string("dd/MM/yyyy")}</#if></td>
+                <td><@w.asCSV person.getSkills()![] /> </p></td>
+                <td><@w.checkbox "selectedIds" "${person.id}" /></td>
+            </tr>
+        </#list>
+    </table>
+
+    <a href="" <a href="" Selected</a>
+
+    <div id="showArea">
+    	Selected people are:
+        <table>
+        <#list selectedPeople as person>
+	        <tr class="odd">
+                <td>${person.firstName} ${person.lastName} (${person.id})</td>
+            </tr>
+        </#list>
+        </table>
+	</div>
+
+    <!-- Example of partial page -->
+    <div id="editArea">
+      <#if person?exists>
+        <#include "editperson.ftl" parse="true">
+      </#if>
+    </div>
+
+</form>
+</body>
+
+</html>
\ No newline at end of file

Deleted: trunk/examples/freemarker-example/src/main/webapp/people/person.htm (628 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/people/person.htm	2008-04-19 15:53:00 UTC (rev 628)
+++ trunk/examples/freemarker-example/src/main/webapp/people/person.htm	2008-04-19 16:04:14 UTC (rev 629)
@@ -1,71 +0,0 @@
-<#import "/ftl/waffle/form.ftl" as w>
-<?xml version="1.0" encoding="UTF-8"?>
-<html xmlns="http://www.w3.org/1999/xhtml">
-
-<head>
-    <title>Select a person</title>
-    <style type="text/css" title="currentStyle" media="screen">
-        @import "../stylesheets/style.css";
-    </style>
-    <script src="" type="text/_javascript_">
-        // keep this space
-    </script>
-    <script src="" type="text/_javascript_">
-        // keep this space
-    </script>
-</head>
-
-<body>
-<form action="" method="post">
-
-    <h3>Waffle example: Select Person</h3>
-
-    <table>
-        <tr>
-            <th>Id</th>
-            <th>First Name</th>
-            <th>Last Name</th>
-            <th>Email</th>
-            <th>Date of Birth</th>
-            <th>Skills</th>
-            <th>Select</th>
-        </tr>
-        <#list people as person>
-            <tr class="odd">
-                <td>
-                    <a href=""
-                </td>
-                <td>${person.firstName}</td>
-                <td>${person.lastName}</td>
-                <td>${person.email}</td>
-                <td><#if person.dateOfBirth??>${person.dateOfBirth?string("dd/MM/yyyy")}</#if></td>
-                <td><@w.asCSV person.getSkills()![] /> </p></td>
-                <td><@w.checkbox "selectedIds" "${person.id}" /></td>
-            </tr>
-        </#list>
-    </table>
-
-    <a href="" <a href="" Selected</a>
-
-    <div id="showArea">
-    	Selected people are:
-        <table>
-        <#list selectedPeople as person>
-	        <tr class="odd">
-                <td>${person.firstName} ${person.lastName} (${person.id})</td>
-            </tr>
-        </#list>
-        </table>
-	</div>
-
-    <!-- Example of partial page -->
-    <div id="editArea">
-      <#if person?exists>
-        <#include "editperson.htm" parse="true">
-      </#if>
-    </div>
-
-</form>
-</body>
-
-</html>
\ No newline at end of file

Deleted: trunk/examples/freemarker-example/src/main/webapp/siteDecorator.htm (628 => 629)

--- trunk/examples/freemarker-example/src/main/webapp/siteDecorator.htm	2008-04-19 15:53:00 UTC (rev 628)
+++ trunk/examples/freemarker-example/src/main/webapp/siteDecorator.htm	2008-04-19 16:04:14 UTC (rev 629)
@@ -1,15 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
-        "http://www.w3.org/TR/html4/loose.dtd">
-<html>
-<head>
-  <title>${title}</title>
-  ${head}
-</head>
-<body>
-  ~ Standard Header ~
-  <hr/>
-    ${body}
-  <hr/>
-  ~ Decorator Added Footer ~
-</body>
-</html>
\ No newline at end of file


To unsubscribe from this list please visit:

http://xircles.codehaus.org/manage_email

Reply via email to