You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by ca...@apache.org on 2007/02/06 09:50:33 UTC
svn commit: r504041 - in
/myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp:
clientValidation.jsp home.jsp
Author: cagatay
Date: Tue Feb 6 00:50:32 2007
New Revision: 504041
URL: http://svn.apache.org/viewvc?view=rev&rev=504041
Log:
Add jsp example of clientvalidation
Added:
myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp/clientValidation.jsp (with props)
Modified:
myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp/home.jsp
Added: myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp/clientValidation.jsp
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp/clientValidation.jsp?view=auto&rev=504041
==============================================================================
--- myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp/clientValidation.jsp (added)
+++ myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp/clientValidation.jsp Tue Feb 6 00:50:32 2007
@@ -0,0 +1,71 @@
+<%@ page session="false" contentType="text/html;charset=utf-8"%>
+<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
+<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
+<%@ taglib uri="http://myfaces.apache.org/tomahawk" prefix="t"%>
+<%@ taglib uri="http://myfaces.apache.org/sandbox" prefix="s"%>
+<html>
+
+<!--
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+//-->
+
+<%@include file="inc/head.inc" %>
+
+<body>
+
+<f:view>
+
+ <h:form id="carForm" onsubmit="return tomahawk.executeClientLifeCycle();">
+
+ <t:messages forceSpan="true" layout="list" />
+
+ <h:panelGrid columns="3">
+ <h:outputText id="lbl_name" value="Name *"></h:outputText>
+ <h:inputText id="txt_name" value="#{customerCreateBean.customer.name}" required="true"></h:inputText>
+ <t:message for="txt_name" forceSpan="true" />
+
+ <h:outputText id="lbl_surname" value="Surname *"></h:outputText>
+ <h:inputText id="txt_surname" value="#{customerCreateBean.customer.surname}" required="true"></h:inputText>
+ <t:message for="txt_surname" forceSpan="true" />
+
+ <h:outputText id="lbl_age" value="Age"></h:outputText>
+ <h:inputText id="txt_age" value="#{customerCreateBean.customer.age}"></h:inputText>
+ <t:message for="txt_age" forceSpan="true" />
+
+ <h:outputText id="lbl_address" value="Adress"></h:outputText>
+ <h:inputText id="txt_address" value="#{customerCreateBean.customer.address}">
+ <f:validateLength minimum="2" maximum="5"/>
+ </h:inputText>
+ <t:message for="txt_address" forceSpan="true" />
+ </h:panelGrid>
+
+ <h:commandButton id="btn_save" value="Create" action=""/>
+
+ <s:validationScript></s:validationScript>
+
+ </h:form>
+
+</f:view>
+
+<%@include file="inc/page_footer.jsp" %>
+
+</body>
+
+</html>
Propchange: myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp/clientValidation.jsp
------------------------------------------------------------------------------
svn:eol-style = native
Modified: myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp/home.jsp
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp/home.jsp?view=diff&rev=504041&r1=504040&r2=504041
==============================================================================
--- myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp/home.jsp (original)
+++ myfaces/tomahawk/trunk/sandbox/examples/src/main/webapp/home.jsp Tue Feb 6 00:50:32 2007
@@ -26,6 +26,10 @@
<f:verbatim><a href="#imageLoop">Image loop - slide show component</a></f:verbatim>
<f:verbatim><a href="#partialPageRendering">Partial Page Rendering</a></f:verbatim>
<f:verbatim><a href="#filterTable">Filter Table</a></f:verbatim>
+ <h:outputText value="Client Side Validation"/>
+ <h:panelGrid style="padding-left:25px">
+ <h:outputLink value="clientValidation.jsf"><f:verbatim>Conversion&Validation at Client Side</f:verbatim></h:outputLink>
+ </h:panelGrid>
</h:panelGrid>
<f:verbatim><a name="partialPageRendering" /></f:verbatim>