You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by sr...@apache.org on 2005/09/17 07:56:25 UTC

svn commit: r289708 [2/4] - in /struts/apps/trunk/cookbook: ./ src/ src/java/ src/java/examples/ src/java/examples/bean/ src/java/examples/dyna/ src/java/examples/links/ src/java/examples/localization/ src/java/examples/logic/ src/java/examples/multibo...

Added: struts/apps/trunk/cookbook/src/java/examples/simple/ProcessSimpleAction.java
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/java/examples/simple/ProcessSimpleAction.java?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/java/examples/simple/ProcessSimpleAction.java (added)
+++ struts/apps/trunk/cookbook/src/java/examples/simple/ProcessSimpleAction.java Fri Sep 16 22:55:45 2005
@@ -0,0 +1,78 @@
+/*
+ * $Id$
+ *
+ * Copyright 2005 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+package examples.simple;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+
+import org.apache.struts.action.Action;
+import org.apache.struts.action.ActionForm;
+import org.apache.struts.action.ActionForward;
+import org.apache.struts.action.ActionMapping;
+
+/**
+ * Retrieve and process data from the submitted form 
+ *
+ * @version $Rev$ $Date$
+ */
+public class ProcessSimpleAction extends Action {
+
+    // ------------------------------------------------------------ Constructors
+
+    /**
+     * Constructor for ProcessFormAction.
+     */
+    public ProcessSimpleAction() {
+        super();
+    }
+
+    // ---------------------------------------------------------- Action Methods
+
+    /**
+     * Process the request and return an <code>ActionForward</code> instance 
+     * describing where and how control should be forwarded, or 
+     * <code>null</code>if the response has already been completed.
+     *
+     * @param mapping The ActionMapping used to select this instance
+     * @param form The optional ActionForm bean for this request (if any)
+     * @param request The HTTP request we are processing
+     * @param response The HTTP response we are creating
+     *
+     * @exception Exception if the application logic throws an exception
+     * 
+     * @return the ActionForward for the next view
+     */
+    public ActionForward execute(
+        ActionMapping mapping,
+        ActionForm form,
+        HttpServletRequest request,
+        HttpServletResponse response)
+        throws Exception {
+
+        // If user pressed 'Cancel' button, 
+        // return to home page
+        if (isCancelled(request)) {
+            return mapping.findForward("home");
+        }
+        
+        // Forward to result page
+        return mapping.findForward("success");
+    }
+
+}

Propchange: struts/apps/trunk/cookbook/src/java/examples/simple/ProcessSimpleAction.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/java/examples/simple/ProcessSimpleAction.java
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/java/examples/simple/SimpleActionForm.java
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/java/examples/simple/SimpleActionForm.java?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/java/examples/simple/SimpleActionForm.java (added)
+++ struts/apps/trunk/cookbook/src/java/examples/simple/SimpleActionForm.java Fri Sep 16 22:55:45 2005
@@ -0,0 +1,233 @@
+/*
+ * $Id$
+ *
+ * Copyright 2005 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+package examples.simple;
+
+import javax.servlet.http.HttpServletRequest;
+
+import org.apache.struts.action.ActionErrors;
+import org.apache.struts.action.ActionForm;
+import org.apache.struts.action.ActionMapping;
+import org.apache.struts.action.ActionMessage;
+
+/**
+ * A simple ActionForm
+ *
+ * @version $Rev$ $Date$
+ */
+public class SimpleActionForm extends ActionForm {
+
+    // ------------------------------------------------------ Instance Variables
+
+    /** Name */
+    private String name = null;
+
+    /** Secret */
+    private String secret = null;
+
+    /** Color */
+    private String color = null;
+
+    /** Confirm */
+    private boolean confirm = false;
+
+    /** Rating */
+    private String rating = null;
+
+    /** Message */
+    private String message = null;
+
+    /** Hidden */
+    private String hidden = null;
+
+    // ------------------------------------------------------------ Constructors
+
+    /**
+     * Constructor for MultiboxActionForm.
+     */
+    public SimpleActionForm() {
+        super();
+    }
+
+    // ---------------------------------------------------------- Public Methods
+
+    /**
+     * Reset all properties to their default values.
+     *
+     * @param mapping The mapping used to select this instance
+     * @param request The servlet request we are processing
+     */
+    public void reset(ActionMapping mapping, HttpServletRequest request) {
+
+        this.name = null;
+        this.secret = null;
+        this.color = null;
+        this.confirm = false;
+        this.rating = null;
+        this.message = null;
+        this.hidden = null;
+
+    }
+
+    /**
+     * Validate the properties that have been set from this HTTP request,
+     * and return an <code>ActionMessages</code> object that encapsulates any
+     * validation errors that have been found.  If no errors are found, return
+     * <code>null</code> or an <code>ActionMessages</code> object with no
+     * recorded error messages.
+     *
+     * @param mapping The mapping used to select this instance
+     * @param request The servlet request we are processing
+     * 
+     * @return ActionMessages if any validation errors occurred
+     */
+    public ActionErrors validate(
+        ActionMapping mapping,
+        HttpServletRequest request) {
+
+        ActionErrors errors = new ActionErrors();
+
+        // Name must be entered
+        if ((name == null) || (name.length() < 1)) {
+            errors.add("name", new ActionMessage("errors.name.required"));
+        }
+
+        // Secret Phrase must be entered
+        if ((secret == null) || (secret.length() < 1)) {
+            errors.add("secret", new ActionMessage("errors.secret.required"));
+        }
+
+        return (errors);
+
+    }
+
+    // -------------------------------------------------------------- Properties
+
+    /**
+     * Returns the color.
+     * @return String
+     */
+    public String getColor() {
+        return color;
+    }
+
+    /**
+     * Returns the confirm.
+     * @return boolean
+     */
+    public boolean getConfirm() {
+        return confirm;
+    }
+
+    /**
+     * Returns the hidden.
+     * @return String
+     */
+    public String getHidden() {
+        return hidden;
+    }
+
+    /**
+     * Returns the message.
+     * @return String
+     */
+    public String getMessage() {
+        return message;
+    }
+
+    /**
+     * Returns the name.
+     * @return String
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * Returns the rating.
+     * @return String
+     */
+    public String getRating() {
+        return rating;
+    }
+
+    /**
+     * Returns the secret.
+     * @return String
+     */
+    public String getSecret() {
+        return secret;
+    }
+
+    /**
+     * Sets the color.
+     * @param color The color to set
+     */
+    public void setColor(String color) {
+        this.color = color;
+    }
+
+    /**
+     * Sets the confirm.
+     * @param confirm The confirm to set
+     */
+    public void setConfirm(boolean confirm) {
+        this.confirm = confirm;
+    }
+
+    /**
+     * Sets the hidden.
+     * @param hidden The hidden to set
+     */
+    public void setHidden(String hidden) {
+        this.hidden = hidden;
+    }
+
+    /**
+     * Sets the message.
+     * @param message The message to set
+     */
+    public void setMessage(String message) {
+        this.message = message;
+    }
+
+    /**
+     * Sets the name.
+     * @param name The name to set
+     */
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    /**
+     * Sets the rating.
+     * @param rating The rating to set
+     */
+    public void setRating(String rating) {
+        this.rating = rating;
+    }
+
+    /**
+     * Sets the secret.
+     * @param secret The secret to set
+     */
+    public void setSecret(String secret) {
+        this.secret = secret;
+    }
+
+}

Propchange: struts/apps/trunk/cookbook/src/java/examples/simple/SimpleActionForm.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/java/examples/simple/SimpleActionForm.java
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/java/examples/token/PrepareTokenAction.java
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/java/examples/token/PrepareTokenAction.java?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/java/examples/token/PrepareTokenAction.java (added)
+++ struts/apps/trunk/cookbook/src/java/examples/token/PrepareTokenAction.java Fri Sep 16 22:55:45 2005
@@ -0,0 +1,79 @@
+/*
+ * $Id$
+ *
+ * Copyright 2005 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+package examples.token;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+
+import org.apache.struts.action.Action;
+import org.apache.struts.action.ActionForm;
+import org.apache.struts.action.ActionForward;
+import org.apache.struts.action.ActionMapping;
+
+/**
+ * Perform any tasks and setup any data that 
+ * must be prepared before the form is displayed.
+ *
+ * @version $Rev$ $Date$
+ */
+public class PrepareTokenAction extends Action {
+
+    // ------------------------------------------------------------ Constructors
+
+    /**
+     * Constructor for PrepareOptionsAction.
+     */
+    public PrepareTokenAction() {
+        super();
+    }
+
+    // ---------------------------------------------------------- Action Methods
+
+    /**
+     * Process the request and return an <code>ActionForward</code> instance 
+     * describing where and how control should be forwarded, or 
+     * <code>null</code>if the response has already been completed.
+     *
+     * @param mapping The ActionMapping used to select this instance
+     * @param form The optional ActionForm bean for this request (if any)
+     * @param request The HTTP request we are processing
+     * @param response The HTTP response we are creating
+     *
+     * @exception Exception if an exception occurs
+     * 
+     * @return the ActionForward to forward control to
+     */
+    public ActionForward execute(
+        ActionMapping mapping,
+        ActionForm form,
+        HttpServletRequest request,
+        HttpServletResponse response)
+        throws Exception {
+
+        // Generate a unique token that will be 
+        // check when the form is submitted
+        saveToken(request);
+       
+
+        // Forward to the form
+        return mapping.findForward("success");
+
+    }
+
+}

Propchange: struts/apps/trunk/cookbook/src/java/examples/token/PrepareTokenAction.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/java/examples/token/PrepareTokenAction.java
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/java/examples/token/ProcessTokenAction.java
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/java/examples/token/ProcessTokenAction.java?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/java/examples/token/ProcessTokenAction.java (added)
+++ struts/apps/trunk/cookbook/src/java/examples/token/ProcessTokenAction.java Fri Sep 16 22:55:45 2005
@@ -0,0 +1,99 @@
+/*
+ * $Id$
+ *
+ * Copyright 2005 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+package examples.token;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+
+import org.apache.struts.action.Action;
+import org.apache.struts.action.ActionErrors;
+import org.apache.struts.action.ActionForm;
+import org.apache.struts.action.ActionForward;
+import org.apache.struts.action.ActionMapping;
+import org.apache.struts.action.ActionMessage;
+import org.apache.struts.action.ActionMessages;
+
+/**
+ * Retrieve and process data from the submitted form 
+ *
+ * @version $Rev$ $Date$
+ */
+public class ProcessTokenAction extends Action {
+
+    // ------------------------------------------------------------ Constructors
+
+    /**
+     * Constructor for ProcessOptionsAction.
+     */
+    public ProcessTokenAction() {
+        super();
+    }
+
+    // ---------------------------------------------------------- Action Methods
+
+    /**
+     * Process the request and return an <code>ActionForward</code> instance 
+     * describing where and how control should be forwarded, or 
+     * <code>null</code>if the response has already been completed.
+     *
+     * @param mapping The ActionMapping used to select this instance
+     * @param form The optional ActionForm bean for this request (if any)
+     * @param request The HTTP request we are processing
+     * @param response The HTTP response we are creating
+     *
+     * @exception Exception if the application logic throws an exception
+     * 
+     * @return the ActionForward for the next view
+     */
+    public ActionForward execute(
+        ActionMapping mapping,
+        ActionForm form,
+        HttpServletRequest request,
+        HttpServletResponse response)
+        throws Exception {
+
+        // If user pressed 'Cancel' button, 
+        // return to home page
+        if (isCancelled(request)) {
+            return mapping.findForward("home");
+        }
+
+        ActionErrors errors = new ActionErrors();
+
+        // Prevent unintentional duplication submissions by checking 
+        // that we have not received this token previously
+        if (!isTokenValid(request)) {
+            errors.add(
+                ActionMessages.GLOBAL_MESSAGE,
+                new ActionMessage("errors.token"));
+        }
+        resetToken(request);
+
+        // Report any errors we have discovered back to the original form
+        if (!errors.isEmpty()) {
+            saveErrors(request, errors);
+            saveToken(request);
+            return (mapping.getInputForward());
+        }
+
+        // Forward to result page
+        return mapping.findForward("success");
+    }
+
+}

Propchange: struts/apps/trunk/cookbook/src/java/examples/token/ProcessTokenAction.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/java/examples/token/ProcessTokenAction.java
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/java/examples/validator/CustomValidator.java
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/java/examples/validator/CustomValidator.java?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/java/examples/validator/CustomValidator.java (added)
+++ struts/apps/trunk/cookbook/src/java/examples/validator/CustomValidator.java Fri Sep 16 22:55:45 2005
@@ -0,0 +1,85 @@
+/*
+ * $Id$
+ *
+ * Copyright 2005 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+package examples.validator;
+
+import javax.servlet.http.HttpServletRequest;
+
+import org.apache.commons.validator.Field;
+import org.apache.commons.validator.GenericValidator;
+import org.apache.commons.validator.ValidatorAction;
+import org.apache.commons.validator.util.ValidatorUtils;
+import org.apache.struts.action.ActionMessages;
+import org.apache.struts.validator.Resources;
+
+/**
+ * A custom validator example
+ *
+ * @version $Rev$ $Date$
+ */
+public class CustomValidator {
+
+    // ------------------------------------------------------------ Constructors
+
+    /**
+     * Constructor for CustomValidator.
+     */
+    public CustomValidator() {
+        super();
+    }
+
+    // ---------------------------------------------------------- Public Methods
+
+    /** 
+     * Example validator for comparing the equality of two fields
+     * 
+     * http://struts.apache.org/userGuide/dev_validator.html
+     * http://www.raibledesigns.com/page/rd/20030226
+     */
+    public static boolean validateTwoFields(
+        Object bean,
+        ValidatorAction va,
+        Field field,
+        ActionMessages errors,
+        HttpServletRequest request) {
+    	
+        String value =
+            ValidatorUtils.getValueAsString(bean, field.getProperty());
+        String property2 = field.getVarValue("secondProperty");
+        String value2 = ValidatorUtils.getValueAsString(bean, property2);
+
+        if (!GenericValidator.isBlankOrNull(value)) {
+            try {
+                if (!value.equals(value2)) {
+                    errors.add(
+                        field.getKey(),
+                        Resources.getActionMessage(request, va, field));
+
+                    return false;
+                }
+            } catch (Exception e) {
+                errors.add(
+                    field.getKey(),
+                    Resources.getActionMessage(request, va, field));
+                return false;
+            }
+        }
+        return true;
+    }
+
+}

Propchange: struts/apps/trunk/cookbook/src/java/examples/validator/CustomValidator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/java/examples/validator/CustomValidator.java
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/java/examples/validator/ProcessValidatorAction.java
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/java/examples/validator/ProcessValidatorAction.java?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/java/examples/validator/ProcessValidatorAction.java (added)
+++ struts/apps/trunk/cookbook/src/java/examples/validator/ProcessValidatorAction.java Fri Sep 16 22:55:45 2005
@@ -0,0 +1,78 @@
+/*
+ * $Id$
+ *
+ * Copyright 2005 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+package examples.validator;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+
+import org.apache.struts.action.Action;
+import org.apache.struts.action.ActionForm;
+import org.apache.struts.action.ActionForward;
+import org.apache.struts.action.ActionMapping;
+
+/**
+ * Retrieve and process data from the submitted form 
+ *
+ * @version $Rev$ $Date$
+ */
+public class ProcessValidatorAction extends Action {
+
+    // ------------------------------------------------------------ Constructors
+
+    /**
+     * Constructor for ProcessOptionsAction.
+     */
+    public ProcessValidatorAction() {
+        super();
+    }
+
+    // ---------------------------------------------------------- Action Methods
+
+    /**
+     * Process the request and return an <code>ActionForward</code> instance 
+     * describing where and how control should be forwarded, or 
+     * <code>null</code>if the response has already been completed.
+     *
+     * @param mapping The ActionMapping used to select this instance
+     * @param form The optional ActionForm bean for this request (if any)
+     * @param request The HTTP request we are processing
+     * @param response The HTTP response we are creating
+     *
+     * @exception Exception if the application logic throws an exception
+     * 
+     * @return the ActionForward for the next view
+     */
+    public ActionForward execute(
+        ActionMapping mapping,
+        ActionForm form,
+        HttpServletRequest request,
+        HttpServletResponse response)
+        throws Exception {
+
+        // If user pressed 'Cancel' button, 
+        // return to home page
+        if (isCancelled(request)) {
+            return mapping.findForward("home");
+        }
+
+        // Forward to result page
+        return mapping.findForward("success");
+    }
+
+}

Propchange: struts/apps/trunk/cookbook/src/java/examples/validator/ProcessValidatorAction.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/java/examples/validator/ProcessValidatorAction.java
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/webapp/WEB-INF/chain-config.xml
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/WEB-INF/chain-config.xml?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/webapp/WEB-INF/chain-config.xml (added)
+++ struts/apps/trunk/cookbook/src/webapp/WEB-INF/chain-config.xml Fri Sep 16 22:55:45 2005
@@ -0,0 +1,259 @@
+<?xml version="1.0" ?>
+
+
+<!--
+
+ Copyright 2002,2004 The Apache Software Foundation.
+ 
+ Licensed 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.
+
+-->
+
+
+<!--
+    This file contains definitions of the standard Chain Of Responsibility
+    chains that emulate Struts 1.x processing functionality.  These chains
+    are defined in a catalog named "struts" so that the application can
+    use the default catalog for its own purposes, without any potential for
+    name clashes.
+
+    $Id$
+-->
+
+
+<catalog       name="struts">
+
+    <define name= "lookup"
+            className= "org.apache.commons.chain.generic.LookupCommand" />
+    <!-- ========== Servlet Complete Request Chain ========================= -->
+
+    <chain     name="servlet-standard">
+
+      <!-- Establish exception handling filter -->
+      <command
+          className="org.apache.struts.chain.commands.ExceptionCatcher"
+        catalogName="struts"
+   exceptionCommand="servlet-exception"/>
+
+      <lookup
+        catalogName="struts"
+               name="process-action"
+           optional="false"/>
+
+      <lookup
+        catalogName="struts"
+               name="process-view"
+           optional="false"/>
+
+    </chain>
+
+
+    <!-- ========== View Processing chain ======================== -->
+   <chain      name="process-action">
+
+      <!--
+           This chain attempts to emulate (most of) the standard request
+           processing in the standard org.apache.struts.action.RequestProcessor
+           class, by performing the corresponding tasks in individual Commands
+           that are composable.  The following list defines a cross reference
+           between the processXxx methods and the Commands that perform the
+           corresponding functionality:
+
+           processMultipart        Integrated into servlet and legacy classes
+
+           processPath             SelectAction (which also does processMapping)
+
+           processException        ExceptionCatcher / ExceptionHandler
+
+           processLocale           SelectLocale
+
+           processContent          SetContentType
+
+           processNoCache          RequestNoCache
+
+           processPreprocess       LookupCommand with optional="true".  Multiple
+                                   occurrences of this can easily be added, to
+                                   support additional processing hooks at any
+                                   point in the chain without modifying the
+                                   standard definition.
+
+           processMapping          SelectAction (which also does processPath)
+
+           processRoles            AuthorizeAction
+
+           processActionForm       CreateActionForm
+
+           processPopulate         PopulateActionForm
+
+           processValidate         ValidateActionForm / SelectInput
+
+           processForward          SelectForward
+
+           processInclude          SelectInclude / PerformInclude
+
+           processActionCreate     CreateAction
+
+           processActionPerform    ExecuteAction
+      -->
+
+
+      <!-- Look up optional preprocess command -->
+      <lookup
+        catalogName="struts"
+               name="servlet-standard-preprocess"
+           optional="true"/>
+
+
+      <!-- Identify the Locale for this request -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.SelectLocale"/>
+ 
+
+      <!-- Set (if needed) the URI of the original request -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.SetOriginalURI"/>
+          
+          
+      <!-- Set (if needed) no cache HTTP response headers -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.RequestNoCache"/>
+          
+          
+      <!-- Set (if needed) the HTTP response content type -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.SetContentType"/>        
+
+
+      <!-- Identify the ActionConfig for this request -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.SelectAction"/>
+          
+          
+      <!-- Authorize the selected ActionConfig for this request -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.AuthorizeAction"/>    
+
+
+      <!-- Create (if needed) the ActionForm for this request -->
+      <command
+          className="org.apache.struts.chain.commands.CreateActionForm"/>
+
+
+      <!-- Populate the ActionForm for this request -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.PopulateActionForm"/>
+
+
+      <!-- Validate the ActionForm for this request -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.ValidateActionForm"/>
+
+
+      <!-- Select the appropriate ForwardConfig for return to input page -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.SelectInput"/>
+       
+       
+      <!-- Lookup and execute a chain command if the current ActionConfig is 
+           so-configured. -->
+      <command
+          className="org.apache.struts.chain.commands.ExecuteCommand"/>
+       
+       
+      <!-- Select the appropriate ForwardConfig for action mappings that only
+           have an ActionForward -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.SelectForward"/>
+      
+      
+      <!-- Select the include uri (if any) for the current action mapping -->
+      <command
+          className="org.apache.struts.chain.commands.SelectInclude"/>
+          
+      
+      <!-- Perform the include (if needed) -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.PerformInclude"/>
+
+
+      <!-- Create (if needed) the Action for this request -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.CreateAction"/>
+
+
+      <!-- Execute the Action for this request -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.ExecuteAction"/>
+    </chain>
+
+    <!-- ========== View Processing chain ======================== -->
+    <chain name="process-view">
+
+
+      <!-- Lookup and execute a chain command if the current ForwardConfig is 
+           so-configured. -->
+      <command
+          className="org.apache.struts.chain.commands.ExecuteForwardCommand"/>
+
+      <!--
+      If you want to use Tiles, uncomment this command, and the one in the
+      'servlet-exception' chain below, and make sure you have the
+      struts-tiles JAR included in your web application.
+
+      <command
+          className="org.apache.struts.tiles.commands.TilesPreProcessor"/>
+      
+      -->
+
+
+      <!-- Follow the returned ForwardConfig (if any) -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.PerformForward"/>
+
+
+    </chain>
+    
+    <!-- ========== Servlet Exception Handler Chain ======================== -->
+
+    <chain     name="servlet-exception">
+
+      <!--
+            This chain is designed to be invoked (by o.a.s.c.ExceptionCatcher)
+            if an unhandled exception is thrown by any subsequent command
+            in a processing chain (including the one that invokes a Struts
+            action).  The standard definition of this chain supports the
+            exception mapping of Struts 1.1, but can be replaced in order
+            to handle exceptions differently.
+      -->
+
+      <!-- Execute the configured exception handler (if any) -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.ExceptionHandler"/>
+
+      <!--
+      If you want to use Tiles, uncomment this command, and the one in the
+      'servlet-standard' chain below. This one is needed to allow Tiles to
+      be used from global exception handlers.
+
+      <command
+          className="org.apache.struts.chain.servlet.TilesPreProcessor"/>
+      -->
+
+      <!-- Follow the returned ForwardConfig (if any) -->
+      <command
+          className="org.apache.struts.chain.commands.servlet.PerformForward"/>
+
+    </chain>
+
+
+</catalog>

Propchange: struts/apps/trunk/cookbook/src/webapp/WEB-INF/chain-config.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/webapp/WEB-INF/chain-config.xml
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/webapp/WEB-INF/struts-config.xml
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/WEB-INF/struts-config.xml?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/webapp/WEB-INF/struts-config.xml (added)
+++ struts/apps/trunk/cookbook/src/webapp/WEB-INF/struts-config.xml Fri Sep 16 22:55:45 2005
@@ -0,0 +1,259 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE struts-config PUBLIC
+          "-//Apache Software Foundation//DTD Struts Configuration 1.3//EN"
+          "http://struts.apache.org/dtds/struts-config_1_3.dtd">
+
+<struts-config>
+
+	<!-- ========== Form Bean Definitions ================================== -->
+	<form-beans>
+		<!-- Simple ActionForm Bean -->
+		<form-bean name="simpleForm" type="examples.simple.SimpleActionForm"/>
+
+		<!-- DynaActionForm Bean for Dyna -->
+		<form-bean name="dynaForm" type="org.apache.struts.action.DynaActionForm">
+	  		<form-property name="name" type="java.lang.String" />
+	  		<form-property name="secret" type="java.lang.String" />
+	  		<form-property name="color" type="java.lang.String" />
+	  		<form-property name="confirm" type="java.lang.Boolean" />
+	  		<form-property name="rating" type="java.lang.String" />
+	  		<form-property name="message" type="java.lang.String" />
+	  		<form-property name="hidden" type="java.lang.String" />
+		</form-bean>
+
+		<!-- DynaActionForm Bean for Options -->
+		<form-bean name="optionsForm" type="org.apache.struts.action.DynaActionForm">
+	  		<form-property name="fruit1" type="java.lang.String" initial="Pear" />
+	  		<form-property name="fruit2" type="java.lang.String" initial="Apple" />
+	  		<form-property name="fruit3" type="java.lang.String[]" initial="Banana Orange" />
+	  		<form-property name="color1" type="java.lang.String" />
+	  		<form-property name="color2" type="java.lang.String" />
+	  		<form-property name="color3" type="java.lang.String" />
+	  		<form-property name="day1" type="java.lang.String" />
+	  		<form-property name="day2" type="java.lang.String" />
+	  		<form-property name="book1" type="java.lang.String" />
+	  		<form-property name="book2" type="java.lang.String" />
+	  		<form-property name="animal1" type="java.lang.String" />
+	  		<form-property name="animal2" type="java.lang.String" />
+		</form-bean>
+
+		<!-- ActionForm Bean for Multibox -->
+		<form-bean name="multiboxForm" type="examples.multibox.MultiboxActionForm"/>
+
+		<!-- DynaActionForm Bean for Bean -->
+		<form-bean name="beanForm" type="org.apache.struts.action.DynaActionForm">
+		</form-bean>
+
+		<!-- General Test Form -->
+		<form-bean name="testForm" type="org.apache.struts.action.DynaActionForm">
+	  		<form-property name="name" type="java.lang.String" />
+	  		<form-property name="secret" type="java.lang.String" />
+	  		<form-property name="color" type="java.lang.String" />
+	  		<form-property name="confirm" type="java.lang.Boolean" />
+	  		<form-property name="rating" type="java.lang.String" />
+	  		<form-property name="message" type="java.lang.String" />
+	  		<form-property name="hidden" type="java.lang.String" />
+		</form-bean>
+
+		<!-- DynaActionForm Bean for Validator -->
+		<form-bean name="validatorForm" type="org.apache.struts.validator.DynaValidatorForm">
+	  		<form-property name="byteValue" type="java.lang.String" />
+	  		<form-property name="creditCard" type="java.lang.String" />
+	  		<form-property name="date" type="java.lang.String" />
+	  		<form-property name="doubleValue" type="java.lang.String" />
+	  		<form-property name="email" type="java.lang.String" />
+	  		<form-property name="floatValue" type="java.lang.String" />
+	  		<form-property name="integerValue" type="java.lang.String" />
+	  		<form-property name="longValue" type="java.lang.String" />
+	  		<form-property name="mask" type="java.lang.String" />
+	  		<form-property name="min" type="java.lang.String" />
+	  		<form-property name="max" type="java.lang.String" />
+	  		<form-property name="range" type="java.lang.String" />
+	  		<form-property name="required" type="java.lang.String" />
+	  		<form-property name="shortValue" type="java.lang.String" />
+	  		<form-property name="password" type="java.lang.String" />
+	  		<form-property name="password2" type="java.lang.String" />
+
+		</form-bean>
+
+	</form-beans>
+
+	<!-- ========= Global Exception Definitions ============================ -->
+	<global-exceptions>
+	</global-exceptions>
+
+	<!-- ========== Global Forward Definitions ============================= -->
+
+	<global-forwards>
+		<forward name="home" path="/index.jsp" redirect="true"/>
+	</global-forwards>
+
+	<!-- ========== Action Mapping Definitions ============================= -->
+	<action-mappings>
+
+		<!-- Simple ActionForm Example ===================================== -->
+
+		<action path="/prepareSimple" 
+				type="examples.SuccessAction">
+			<forward name="success" path="/jsp/simple/Simple.jsp"/>
+		</action>
+
+		<action path="/processSimple" 
+				type="examples.simple.ProcessSimpleAction" 
+				name="simpleForm" 
+				scope="request" 
+				input="/jsp/simple/Simple.jsp"
+				validate="true">
+			<forward name="success" path="/jsp/simple/SimpleResults.jsp"/>
+		</action>
+
+		<!-- DynaActionForm Example ======================================== -->
+
+		<action path="/prepareDyna" 
+				type="examples.SuccessAction">
+			<forward name="success" path="/jsp/dyna/Dyna.jsp"/>
+		</action>
+
+		<action path="/processDyna" 
+				type="examples.dyna.ProcessDynaAction"
+				name="dynaForm" 
+				scope="request" 
+				input="/jsp/dyna/Dyna.jsp"
+				validate="false">
+			<forward name="success" path="/jsp/dyna/DynaResults.jsp"/>
+		</action>
+
+		<!-- Options Example =============================================== -->
+
+		<action path="/prepareOptions" 
+				type="examples.options.PrepareOptionsAction">
+			<forward name="success" path="/jsp/options/Options.jsp"/>
+		</action>
+
+		<action path="/processOptions" 
+				type="examples.options.ProcessOptionsAction" 
+				name="optionsForm" 
+				scope="request" 
+				input="/jsp/options/Options.jsp"
+				validate="false">
+			<forward name="success" path="/jsp/options/OptionsResults.jsp"/>
+		</action>
+
+		<!-- Mutibox Example =============================================== -->
+
+		<action path="/prepareMultibox" 
+				type="examples.multibox.PrepareMultiboxAction"
+				name="multiboxForm" 
+				scope="request" 
+				validate="false">
+			<forward name="success" path="/jsp/multibox/Multibox.jsp"/>
+		</action>
+
+		<action path="/processMultibox" 
+				type="examples.multibox.ProcessMultiboxAction" 
+				name="multiboxForm" 
+				scope="request" 
+				input="/jsp/multibox/Multibox.jsp"
+				validate="false">
+			<forward name="success" path="/jsp/multibox/MultiboxResults.jsp"/>
+		</action>
+
+		<!-- Bean Tags Example ============================================= -->
+
+		<action path="/prepareBean" 
+				type="examples.bean.PrepareBeanAction">
+			<forward name="success" path="/jsp/bean/Bean.jsp"/>
+		</action>
+
+		<!-- Links Tags Example ============================================ -->
+
+		<action path="/prepareLinks" 
+				type="examples.links.PrepareLinksAction">
+			<forward name="success" path="/jsp/links/Links.jsp"/>
+		</action>
+
+		<action path="/processLinks" 
+				type="examples.links.ProcessLinksAction" 
+				name="testForm" 
+				scope="request" 
+				input="/jsp/links/Links.jsp"
+				validate="false">
+			<forward name="success" path="/jsp/links/LinksResults.jsp"/>
+		</action>	
+
+		<!-- Logic Tags Example ============================================ -->
+
+		<action path="/prepareLogic" 
+				type="examples.logic.PrepareLogicAction">
+			<forward name="success" path="/jsp/logic/Logic.jsp"/>
+		</action>
+
+		<!-- Validator Example ============================================= -->
+
+		<action path="/prepareValidator" 
+				type="examples.SuccessAction">
+			<forward name="success" path="/jsp/validator/Validator.jsp"/>
+		</action>
+
+		<action path="/processValidator" 
+				type="examples.validator.ProcessValidatorAction" 
+				name="validatorForm" 
+				scope="request" 
+				input="/jsp/validator/Validator.jsp"
+				validate="true">
+			<forward name="success" path="/jsp/validator/ValidatorResults.jsp"/>
+		</action>	
+		
+		<!-- Messages Tags Example ========================================= -->
+
+		<action path="/prepareMessages" 
+				type="examples.SuccessAction">
+			<forward name="success" path="/jsp/messages/Messages.jsp"/>
+		</action>
+		
+		<!-- Localization Tags Example ===================================== -->
+
+		<action path="/prepareLocalization" 
+				type="examples.SuccessAction">
+			<forward name="success" path="/jsp/localization/Localization.jsp"/>
+		</action>
+
+		<action path="/processLocalization" 
+				type="examples.localization.ProcessLocalizationAction" 
+				name="testForm" 
+				scope="request" 
+				input="/jsp/localization/Localization.jsp"
+				validate="false">
+			<forward name="success" path="/jsp/localization/Localization.jsp"/>
+		</action>
+		
+		<!-- Token Tags Example ============================================ -->
+
+		<action path="/prepareToken" 
+				type="examples.token.PrepareTokenAction">
+			<forward name="success" path="/jsp/token/Token.jsp"/>
+		</action>
+
+		<action path="/processToken" 
+				type="examples.token.ProcessTokenAction" 
+				name="testForm" 
+				scope="request" 
+				input="/jsp/token/Token.jsp"
+				validate="false">
+			<forward name="success" path="/jsp/token/TokenResults.jsp"/>
+		</action>		
+
+	</action-mappings>
+
+	<!-- ========== Message Resources Definitions =========================== -->
+
+	<message-resources parameter="examples.MessageResources" />
+
+  	<!-- ========== Plug Ins Configuration ================================== -->
+  	<plug-in className="org.apache.struts.validator.ValidatorPlugIn">
+		<set-property property="pathnames" 
+					  value="/WEB-INF/validator-rules.xml,
+                   			 /WEB-INF/validation.xml" />
+    </plug-in>
+
+</struts-config>
\ No newline at end of file

Propchange: struts/apps/trunk/cookbook/src/webapp/WEB-INF/struts-config.xml
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/webapp/WEB-INF/validation.xml
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/WEB-INF/validation.xml?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/webapp/WEB-INF/validation.xml (added)
+++ struts/apps/trunk/cookbook/src/webapp/WEB-INF/validation.xml Fri Sep 16 22:55:45 2005
@@ -0,0 +1,137 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+<!DOCTYPE form-validation PUBLIC
+          "-//Apache Software Foundation//DTD Commons Validator Rules Configuration 1.1.3//EN"
+          "http://jakarta.apache.org/commons/dtds/validator_1_1_3.dtd">
+
+<form-validation>
+
+	<global>
+		<!-- Custom Validator -->
+		<validator name="twofields" 
+                   classname="examples.validator.CustomValidator" 
+                   method="validateTwoFields" 
+                   methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       javax.servlet.http.HttpServletRequest" 
+                   msg="errors.twofields" />
+	</global>
+
+	<formset>
+
+		<!-- Form for Validation example -->
+		<form name="validatorForm">
+
+			<field property="byteValue" depends="byte">
+				<arg key="prompt.byte" />
+			</field>
+
+			<field property="shortValue" depends="short">
+				<arg key="prompt.short" />
+			</field>
+
+			<field property="integerValue" depends="integer">
+				<arg key="prompt.integer" />
+			</field>
+
+			<field property="longValue" depends="long">
+				<arg key="prompt.long" />
+			</field>
+
+			<field property="floatValue" depends="float">
+				<arg key="prompt.float" />
+			</field>
+
+			<field property="doubleValue" depends="double">
+				<arg key="prompt.double" />
+			</field>
+
+			<field property="creditCard" depends="creditCard">
+				<arg key="prompt.creditCard" />
+			</field>
+
+			<field property="date" depends="date">
+				<arg key="prompt.date" />
+				<var>
+					<var-name>datePattern</var-name>
+					<var-value>MM/dd/yyyy</var-value>
+				</var>
+			</field>
+
+			<field property="email" depends="email">
+				<arg key="prompt.email" />
+			</field>
+
+			<field property="mask" depends="mask">
+				<arg key="prompt.mask" />
+				<var>
+					<var-name>mask</var-name>
+					<var-value>^\d{5}\d*$</var-value>
+				</var>
+			</field>
+
+			<field property="min" depends="minlength">
+				<arg key="prompt.min" position="0"/>
+		        <arg name="minlength" key="${var:minlength}" resource="false" position="1" />
+				<var>
+					<var-name>minlength</var-name>
+					<var-value>5</var-value>
+				</var>
+			</field>
+
+			<field property="max" depends="maxlength">
+				<arg key="prompt.max" position="0"/>
+		        <arg name="maxlength" key="${var:maxlength}" resource="false" position="1" />
+				<var>
+					<var-name>maxlength</var-name>
+					<var-value>10</var-value>
+				</var>
+			</field>
+
+            <field property="range" depends="integer,intRange">
+                <arg key="prompt.range" />
+                <arg name="intRange" key="${var:min}" resource="false" position="1" />
+                <arg name="intRange" key="${var:max}" resource="false" position="2" />
+				<var>
+					<var-name>min</var-name>
+					<var-value>100</var-value>
+				</var>
+				<var>
+					<var-name>max</var-name>
+					<var-value>1000</var-value>
+				</var>
+
+			</field>
+
+			<field property="required" depends="required">
+				<arg key="prompt.required" />
+			</field>
+
+			<!-- Not until post 1.1 
+				<field property="password2" depends="validwhen">
+				<arg0 key="prompt.password2" />
+				<var>
+				<var-name>test</var-name>
+				<var-value>((password == null) or (*this* == password))</var-value>
+				</var>      
+				</field>
+			-->
+
+			<field property="password" depends="required,minlength,twofields">
+				<arg key="prompt.password" position="0"/>
+				<arg name="minlength" key="${var:minlength}" resource="false"  position="1"/>
+				<arg name="twofields" key="prompt.password2"  position="1"/>
+				<var>
+					<var-name>minlength</var-name>
+					<var-value>5</var-value>
+				</var>
+				<var>
+					<var-name>secondProperty</var-name>
+					<var-value>password2</var-value>
+				</var>
+			</field>
+
+		</form>
+	</formset>
+</form-validation>
\ No newline at end of file

Propchange: struts/apps/trunk/cookbook/src/webapp/WEB-INF/validation.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/webapp/WEB-INF/validation.xml
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/webapp/WEB-INF/validator-rules.xml
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/WEB-INF/validator-rules.xml?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/webapp/WEB-INF/validator-rules.xml (added)
+++ struts/apps/trunk/cookbook/src/webapp/WEB-INF/validator-rules.xml Fri Sep 16 22:55:45 2005
@@ -0,0 +1,403 @@
+<!DOCTYPE form-validation PUBLIC
+          "-//Apache Software Foundation//DTD Commons Validator Rules Configuration 1.1.3//EN"
+          "http://jakarta.apache.org/commons/dtds/validator_1_1_3.dtd">
+<!--
+  $Id$
+
+   This file contains the default Struts Validator pluggable validator
+   definitions.  It should be placed somewhere under /WEB-INF and
+   referenced in the struts-config.xml under the plug-in element
+   for the ValidatorPlugIn.
+
+      <plug-in className="org.apache.struts.validator.ValidatorPlugIn">
+        <set-property property="pathnames" value="/WEB-INF/validator-rules.xml,
+                                                  /WEB-INF/validation.xml"/>
+      </plug-in>
+
+   These are the default error messages associated with
+   each validator defined in this file.  They should be
+   added to your projects ApplicationResources.properties
+   file or you can associate new ones by modifying the
+   pluggable validators msg attributes in this file.
+
+   # Struts Validator Error Messages
+   errors.required={0} is required.
+   errors.minlength={0} can not be less than {1} characters.
+   errors.maxlength={0} can not be greater than {1} characters.
+   errors.invalid={0} is invalid.
+
+   errors.byte={0} must be a byte.
+   errors.short={0} must be a short.
+   errors.integer={0} must be an integer.
+   errors.long={0} must be a long.
+   errors.float={0} must be a float.
+   errors.double={0} must be a double.
+
+   errors.date={0} is not a date.
+   errors.range={0} is not in the range {1} through {2}.
+   errors.creditcard={0} is an invalid credit card number.
+   errors.email={0} is an invalid e-mail address.
+
+   Note: Starting in Struts 1.2.0 the default javascript definitions have
+         been consolidated to commons-validator. The default can be overridden
+         by supplying a <javascript> element with a CDATA section, just as
+         in struts 1.1.
+
+-->
+
+<form-validation>
+
+   <global>
+
+      <validator name="required"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateRequired"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+                  msg="errors.required"/>
+
+      <validator name="requiredif"
+                 classname="org.apache.struts.validator.FieldChecks"
+                 method="validateRequiredIf"
+                 methodParams="java.lang.Object,
+                               org.apache.commons.validator.ValidatorAction,
+                               org.apache.commons.validator.Field,
+                               org.apache.struts.action.ActionMessages,
+                               org.apache.commons.validator.Validator,
+                               javax.servlet.http.HttpServletRequest"
+                 msg="errors.required"/>
+
+      <validator name="validwhen"
+          msg="errors.required"
+                 classname="org.apache.struts.validator.validwhen.ValidWhen"
+                 method="validateValidWhen"
+                 methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"/>
+
+
+      <validator name="minlength"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateMinLength"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.minlength"
+           jsFunction="org.apache.commons.validator.javascript.validateMinLength"/>
+
+
+      <validator name="maxlength"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateMaxLength"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.maxlength"
+           jsFunction="org.apache.commons.validator.javascript.validateMaxLength"/>
+
+
+
+      <validator name="mask"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateMask"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.invalid"/>
+
+
+      <validator name="byte"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateByte"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.byte"
+       jsFunctionName="ByteValidations"/>
+
+
+      <validator name="short"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateShort"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.short"
+       jsFunctionName="ShortValidations"/>
+
+
+      <validator name="integer"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateInteger"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.integer"
+       jsFunctionName="IntegerValidations"/>
+
+
+
+      <validator name="long"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateLong"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.long"/>
+
+
+      <validator name="float"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateFloat"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.float"
+       jsFunctionName="FloatValidations"/>
+
+      <validator name="double"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateDouble"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.double"/>
+
+
+      <validator name="byteLocale"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateByteLocale"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.byte"/>
+
+
+      <validator name="shortLocale"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateShortLocale"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.short"/>
+
+
+      <validator name="integerLocale"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateIntegerLocale"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.integer"/>
+
+
+
+      <validator name="longLocale"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateLongLocale"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.long"/>
+
+
+      <validator name="floatLocale"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateFloatLocale"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.float"/>
+
+      <validator name="doubleLocale"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateDoubleLocale"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.double"/>
+                  
+                  
+      <validator name="date"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateDate"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.date"
+       jsFunctionName="DateValidations"/>
+
+
+      <validator name="intRange"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateIntRange"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends="integer"
+                  msg="errors.range"/>
+
+      <validator name="longRange"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateLongRange"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends="long"
+                  msg="errors.range"/>
+
+
+      <validator name="floatRange"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateFloatRange"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends="float"
+                  msg="errors.range"/>
+
+      <validator name="doubleRange"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateDoubleRange"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends="double"
+                  msg="errors.range"/>
+
+
+      <validator name="creditCard"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateCreditCard"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.creditcard"/>
+
+
+      <validator name="email"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateEmail"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.email"/>
+
+      <validator name="url"
+            classname="org.apache.struts.validator.FieldChecks"
+               method="validateUrl"
+         methodParams="java.lang.Object,
+                       org.apache.commons.validator.ValidatorAction,
+                       org.apache.commons.validator.Field,
+                       org.apache.struts.action.ActionMessages,
+                       org.apache.commons.validator.Validator,
+                       javax.servlet.http.HttpServletRequest"
+              depends=""
+                  msg="errors.url"/>
+
+     <!--
+       This simply allows struts to include the validateUtilities into a page, it should
+       not be used as a validation rule.
+     -->
+     <validator name="includeJavaScriptUtilities"
+            classname=""
+               method=""
+         methodParams=""
+              depends=""
+                  msg=""
+           jsFunction="org.apache.commons.validator.javascript.validateUtilities"/>
+
+   </global>
+
+</form-validation>

Propchange: struts/apps/trunk/cookbook/src/webapp/WEB-INF/validator-rules.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/webapp/WEB-INF/validator-rules.xml
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/webapp/WEB-INF/web.xml
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/WEB-INF/web.xml?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/webapp/WEB-INF/web.xml (added)
+++ struts/apps/trunk/cookbook/src/webapp/WEB-INF/web.xml Fri Sep 16 22:55:45 2005
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+
+  <!DOCTYPE web-app PUBLIC
+	"-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
+	"http://java.sun.com/dtd/web-app_2_3.dtd">
+
+<web-app>
+  <display-name>Struts Examples Application</display-name>
+  <!-- Standard Action Servlet Configuration (with debugging) -->
+  <servlet>
+    <servlet-name>action</servlet-name>
+    <servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
+    <init-param>
+      <param-name>config</param-name>
+      <param-value>/WEB-INF/struts-config.xml</param-value>
+    </init-param>
+    <load-on-startup>2</load-on-startup>
+  </servlet>
+
+  <!-- Standard Action Servlet Mapping -->
+  <servlet-mapping>
+    <servlet-name>action</servlet-name>
+    <url-pattern>*.do</url-pattern>
+  </servlet-mapping>
+
+  <!-- The Usual Welcome File List -->
+  <welcome-file-list>
+    <welcome-file>index.jsp</welcome-file>
+  </welcome-file-list>
+
+</web-app>

Propchange: struts/apps/trunk/cookbook/src/webapp/WEB-INF/web.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/webapp/WEB-INF/web.xml
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/webapp/css/example.css
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/css/example.css?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/webapp/css/example.css (added)
+++ struts/apps/trunk/cookbook/src/webapp/css/example.css Fri Sep 16 22:55:45 2005
@@ -0,0 +1,22 @@
+body {
+	margin: 2% 10%;
+	font: 12px/1.4 Verdana, Geneva, Arial, Helvetica, sans-serif;
+}
+
+h1 { font-size: 20px; }
+h2 { font-size: 16px; margin: 3em 0 0.5em; }
+h3 { font-size: 14px; margin: 2em 0 0.5em; }
+h4 { font-size: 12px; }
+h5 { font-size: 11px; }
+h6 { font-size: 10px; }
+
+hr { color: #999999; height: 1px; }
+
+img { border: none; }
+th { text-align: left; }
+
+.error { color: #FF0000; }
+.icon { float: right; margin: 5px; }
+.intro { font-size: 14px;  line-height: 1.6; font-weight: bold;} 
+.label {	font-weight: bold; width: 260px; }
+.result { width: 100%; background: #eef; }

Propchange: struts/apps/trunk/cookbook/src/webapp/css/example.css
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/webapp/css/example.css
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Added: struts/apps/trunk/cookbook/src/webapp/images/code.gif
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/images/code.gif?rev=289708&view=auto
==============================================================================
Binary file - no diff available.

Propchange: struts/apps/trunk/cookbook/src/webapp/images/code.gif
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Propchange: struts/apps/trunk/cookbook/src/webapp/images/code.gif
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: struts/apps/trunk/cookbook/src/webapp/images/execute.gif
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/images/execute.gif?rev=289708&view=auto
==============================================================================
Binary file - no diff available.

Propchange: struts/apps/trunk/cookbook/src/webapp/images/execute.gif
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Propchange: struts/apps/trunk/cookbook/src/webapp/images/execute.gif
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: struts/apps/trunk/cookbook/src/webapp/images/jsp.gif
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/images/jsp.gif?rev=289708&view=auto
==============================================================================
Binary file - no diff available.

Propchange: struts/apps/trunk/cookbook/src/webapp/images/jsp.gif
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Propchange: struts/apps/trunk/cookbook/src/webapp/images/jsp.gif
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: struts/apps/trunk/cookbook/src/webapp/images/return.gif
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/images/return.gif?rev=289708&view=auto
==============================================================================
Binary file - no diff available.

Propchange: struts/apps/trunk/cookbook/src/webapp/images/return.gif
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Propchange: struts/apps/trunk/cookbook/src/webapp/images/return.gif
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: struts/apps/trunk/cookbook/src/webapp/images/valid-xhtml10.png
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/images/valid-xhtml10.png?rev=289708&view=auto
==============================================================================
Binary file - no diff available.

Propchange: struts/apps/trunk/cookbook/src/webapp/images/valid-xhtml10.png
------------------------------------------------------------------------------
    svn:keywords = date author id rev

Propchange: struts/apps/trunk/cookbook/src/webapp/images/valid-xhtml10.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: struts/apps/trunk/cookbook/src/webapp/index.jsp
URL: http://svn.apache.org/viewcvs/struts/apps/trunk/cookbook/src/webapp/index.jsp?rev=289708&view=auto
==============================================================================
--- struts/apps/trunk/cookbook/src/webapp/index.jsp (added)
+++ struts/apps/trunk/cookbook/src/webapp/index.jsp Fri Sep 16 22:55:45 2005
@@ -0,0 +1,190 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<%@ page language="java" contentType="text/html; charset=utf-8" %>
+<%@ taglib uri="http://struts.apache.org/tags-bean" prefix="bean" %>
+<%@ taglib uri="http://struts.apache.org/tags-html" prefix="html" %>
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+<title>Struts Examples</title>
+<html:xhtml/>
+<html:base/>
+<link href="css/example.css" rel="stylesheet" type="text/css" />
+</head>
+<body>
+<h2>Struts Examples with Code</h2>
+<p>This is a collection of examples which demonstrate some of the more frequently
+  used Struts Tags. Familiarity with the Java(tm) Programming Language and HTML
+  is assumed. </p>
+<p>To navigate your way through the examples, the following icons will help: </p>
+<table border="0" cellspacing="5" width="85%" >
+  <tr valign="top">
+    <td width="30"><img alt="" src="images/execute.gif" /></td>
+    <td>Execute the example</td>
+  </tr>
+  <tr valign="top">
+    <td width="30"><img alt="" src="images/return.gif" height="24" width="24" /></td>
+    <td>Return to this screen</td>
+  </tr>
+  <tr valign="top">
+    <td><img alt="" src="images/code.gif" height="24" width="24" /></td>
+    <td>View the source code for the example</td>
+  </tr>
+</table>
+<br />
+<table width="85%" border="0" cellpadding="2" cellspacing="5">
+  <tr valign="top">
+    <td>Simple Form using ActionForm</td>
+    <td>
+		<html:link action="/prepareSimple">
+		  <img src="images/execute.gif" alt="" hspace="4" border="0"  align="top" class="inline" />
+		</html:link>
+		<html:link action="/prepareSimple">Execute</html:link>
+	</td>
+    <td>
+	    <html:link page="/jsp/simple/source.jsp">
+	      <img src="images/code.gif" alt="" width="24" height="24" hspace="4" border="0" align="top" class="inline" />
+		</html:link>
+	    <html:link page="/jsp/simple/source.jsp">
+	      View source
+		</html:link>
+	</td>
+  </tr>
+  <tr valign="top">
+    <td>Simple Form using DynaActionForm</td>
+    <td>
+		<html:link action="/prepareDyna">
+		  <img src="images/execute.gif" alt="" hspace="4" border="0"  align="top" class="inline" />
+		</html:link>
+		<html:link action="/prepareDyna">Execute</html:link>
+	</td>
+    <td>
+	    <html:link page="/jsp/dyna/source.jsp">
+	      <img src="images/code.gif" alt="" width="24" height="24" hspace="4" border="0" align="top" class="inline" />
+		</html:link>
+	    <html:link page="/jsp/dyna/source.jsp">
+	      View source
+		</html:link>
+	</td>
+  </tr>
+  <tr valign="top">
+    <td>Select and Options tags</td>
+    <td>
+		<html:link action="/prepareOptions">
+		  <img src="images/execute.gif" alt="" hspace="4" border="0"  align="top" class="inline" />
+		</html:link>
+		<html:link action="/prepareOptions">Execute</html:link>
+	</td>
+    <td>
+	    <html:link page="/jsp/options/source.jsp">
+	      <img src="images/code.gif" alt="" width="24" height="24" hspace="4" border="0" align="top" class="inline" />
+		</html:link>
+	    <html:link page="/jsp/options/source.jsp">
+	      View source
+		</html:link>
+	</td>
+  </tr>
+  <tr valign="top">
+    <td>Multibox (for checkboxes)</td>
+    <td>
+		<html:link action="/prepareMultibox">
+		  <img src="images/execute.gif" alt="" hspace="4" border="0"  align="top" class="inline" />
+		</html:link>
+		<html:link action="/prepareMultibox">Execute</html:link>
+	</td>
+    <td>
+	    <html:link page="/jsp/multibox/source.jsp">
+	      <img src="images/code.gif" alt="" width="24" height="24" hspace="4" border="0" align="top" class="inline" />
+		</html:link>
+	    <html:link page="/jsp/multibox/source.jsp">
+	      View source
+		</html:link>
+	</td>
+  </tr>
+  <tr valign="top">
+    <td>Bean tags</td>
+    <td> <html:link action="/prepareBean?param1=Test1&amp;param2=Test2"  > <img src="images/execute.gif" alt="" hspace="4" border="0"  align="top" class="inline" /> </html:link> <html:link action="/prepareBean?param1=Test1&amp;param2=Test2">Execute</html:link> </td>
+    <td> <html:link page="/jsp/bean/source.jsp"> <img src="images/code.gif" alt="" width="24" height="24" hspace="4" border="0" align="top" class="inline" /> </html:link> <html:link page="/jsp/bean/source.jsp"> View
+        source </html:link> </td>
+  </tr>
+  <tr valign="top">
+    <td>Logic tags</td>
+    <td><html:link action="/prepareLogic">
+		  <img src="images/execute.gif" alt="" hspace="4" border="0"  align="top" class="inline" />
+		</html:link>
+		<html:link action="/prepareLogic">Execute</html:link>
+	</td>
+    <td><html:link page="/jsp/logic/source.jsp">
+		  <img src="images/code.gif" alt="" width="24" height="24" hspace="4" border="0" align="top" class="inline" />
+		</html:link>
+		<html:link page="/jsp/logic/source.jsp">View source</html:link>
+	</td>
+  </tr>
+  <tr valign="top">
+    <td>Links</td>
+    <td><html:link action="/prepareLinks">
+		  <img src="images/execute.gif" alt="" hspace="4" border="0"  align="top" class="inline" />
+		</html:link>
+		<html:link action="/prepareLinks">Execute</html:link>
+	</td>
+    <td><html:link page="/jsp/links/source.jsp">
+		  <img src="images/code.gif" alt="" width="24" height="24" hspace="4" border="0" align="top" class="inline" />
+		</html:link>
+		<html:link page="/jsp/links/source.jsp">View source</html:link>
+	</td>
+  </tr>
+  <tr valign="top">
+    <td>Validator</td>
+    <td><html:link action="/prepareValidator">
+		  <img src="images/execute.gif" alt="" hspace="4" border="0"  align="top" class="inline" />
+		</html:link>
+		<html:link action="/prepareValidator">Execute</html:link>
+	</td>
+    <td><html:link page="/jsp/validator/source.jsp">
+		  <img src="images/code.gif" alt="" width="24" height="24" hspace="4" border="0" align="top" class="inline" />
+		</html:link>
+		<html:link page="/jsp/validator/source.jsp">View source</html:link>
+	</td>
+  </tr>
+  <tr valign="top">
+    <td>Message resources</td>
+    <td><html:link action="/prepareMessages">
+		  <img src="images/execute.gif" alt="" hspace="4" border="0"  align="top" class="inline" />
+		</html:link>
+	<html:link action="/prepareMessages">Execute</html:link>	</td>
+    <td><html:link page="/jsp/messages/source.jsp">
+		  <img src="images/code.gif" alt="" width="24" height="24" hspace="4" border="0" align="top" class="inline" />
+		</html:link>
+		<html:link page="/jsp/messages/source.jsp">View source</html:link>	</td>
+  </tr>
+  <tr valign="top">
+    <td>Localization</td>
+    <td><html:link action="/prepareLocalization">
+		  <img src="images/execute.gif" alt="" hspace="4" border="0"  align="top" class="inline" />
+		</html:link>
+		<html:link action="/prepareLocalization">Execute</html:link>
+	</td>
+    <td><html:link page="/jsp/localization/source.jsp">
+		  <img src="images/code.gif" alt="" width="24" height="24" hspace="4" border="0" align="top" class="inline" />
+		</html:link>
+		<html:link page="/jsp/localization/source.jsp">View source</html:link>
+	</td>
+  </tr>
+  <tr valign="top">
+    <td>Control duplication form submission</td>
+    <td><html:link action="/prepareToken">
+		  <img src="images/execute.gif" alt="" hspace="4" border="0"  align="top" class="inline" />
+		</html:link>
+		<html:link action="/prepareToken">Execute</html:link>
+	</td>
+    <td><html:link page="/jsp/token/source.jsp">
+		  <img src="images/code.gif" alt="" width="24" height="24" hspace="4" border="0" align="top" class="inline" />
+		</html:link>
+		<html:link page="/jsp/token/source.jsp">View source</html:link>
+	</td>
+  </tr>
+</table>
+<p><img src="images/valid-xhtml10.png" alt="Valid XHTML 1.0!" height="31" width="88" /></p>
+</body>
+
+</html>
\ No newline at end of file

Propchange: struts/apps/trunk/cookbook/src/webapp/index.jsp
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: struts/apps/trunk/cookbook/src/webapp/index.jsp
------------------------------------------------------------------------------
    svn:keywords = date author id rev



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org