You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by an...@leonidae.org on 2004/03/10 18:54:51 UTC

Newbie needs help: Validator not working with Struts/Velocity

I'm fairly new to Struts, and have been trying to get my simple 
application to work - using Struts 1.1, Velocity 1.3.1, Velocity 
Tools 1.1-rc1, and Tomcat 4.1.29. The application (such as it is)
works as far as presentation and workflow - but _isn't_ working is
the Validator framework. I've spent the last day mining the web for
help and haven't been able to progress at all...

The validator files _are_ being loaded - I see them in the log
files. And the rules/formset are being parsed - again, I see it in
the log. However, when the form is submitted on the first page
(payment.vm) and it goes to the second...no validation takes place.
No errors are appearing in either the catalina.out or localhost
log file. I have kicked up the log level to trace and still see
nothing wrong - other than the validation doesn't seem to happen.

Any help or suggestions would be GREATLY appreciated - I'm rather
stuck at the moment. I'm sure its just some silly configuration
or other error...

I'm including all the relevant files inline below. 

Thank you very much

  Andy Akins
  
====== web.xml

<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE web-app
  PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
  "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
<web-app>
  <display-name>CCPAY</display-name>  
  <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>
    <init-param>
      <param-name>debug</param-name>
      <param-value>2</param-value>
    </init-param>
    <init-param>
      <param-name>detail</param-name>
      <param-value>2</param-value>
    </init-param>
    <init-param>
      <param-name>validate</param-name>
      <param-value>true</param-value>
    </init-param>
    <load-on-startup>2</load-on-startup>
  </servlet>
  <servlet>
    <servlet-name>velocity</servlet-name>
    <servlet-class>org.apache.velocity.tools.view.servlet.VelocityViewServlet</servlet-class>
    <init-param>
      <param-name>org.apache.velocity.toolbox</param-name>
      <param-value>/WEB-INF/toolbox.xml</param-value>
    </init-param>
    <init-param>
      <param-name>org.apache.velocity.properties</param-name>
      <param-value>/WEB-INF/velocity.properties</param-value>
   </init-param>
   <load-on-startup>10</load-on-startup>
  </servlet>
  <servlet-mapping>
    <servlet-name>action</servlet-name>
    <url-pattern>*.do</url-pattern>
  </servlet-mapping>
  <servlet-mapping>
    <servlet-name>velocity</servlet-name>
    <url-pattern>*.vm</url-pattern>
  </servlet-mapping>
  <welcome-file-list>
    <welcome-file>index.html</welcome-file>
  </welcome-file-list>
</web-app>

===== struts-config.xml
<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE struts-config PUBLIC
          "-//Apache Software Foundation//DTD Struts Configuration 1.1//EN"
          "http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd">
<struts-config>
  <form-beans>
    <form-bean name="paymentForm" type="org.apache.struts.validator.DynaValidatorForm">
      <form-property name="amount" type="java.lang.String" initial="boo" />
    </form-bean>
  </form-beans>
  <action-mappings>
    <action path="/Payment"
      type="org.apache.struts.actions.ForwardAction"
      name="paymentForm"
      validate="false"
      parameter="/payment.vm"/>
    <action path="/Processing"
      type="org.apache.struts.actions.ForwardAction"
      name="paymentForm"
      input="/Payment.do"
      validate="true"
      parameter="/processing.vm"/>
  </action-mappings>
  <message-resources parameter="application" />
  <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>

===== validation.xml - I'm using the standard validate-rules.xml
<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE form-validation PUBLIC
  "-//Apache Software Foundation//DTD Commons Validator Rules Configuration 1.0//EN"
  "http://jakarta.apache.org/commons/dtds/validator_1_0.dtd">
<form-validation>
  <formset>
    <form name="paymentForm">
      <field property="amount"
        depends="required,email">
        <msg name="email" key="errors.invalid"/>
        <arg0 key="paymentForm.label.amount" />
      </field>
    </form>
  </formset>
</form-validation>

===== Toolbox.xml
<?xml version="1.0"?>

<toolbox>
  <tool>
     <key>link</key>
     <class>org.apache.velocity.tools.struts.StrutsLinkTool</class>
  </tool>
  <tool>
     <key>slink</key>
     <class>org.apache.velocity.tools.struts.SecureLinkTool</class>
  </tool>
  <tool>
     <key>text</key>
     <class>org.apache.velocity.tools.struts.MessageTool</class>
  </tool>
  <tool>
     <key>errors</key>
     <class>org.apache.velocity.tools.struts.ErrorsTool</class>
  </tool>
  <tool>
     <key>messages</key>
     <class>org.apache.velocity.tools.struts.ActionMessagesTool</class>
  </tool>
  <tool>
     <key>form</key>
     <class>org.apache.velocity.tools.struts.FormTool</class>
  </tool>
  <tool>
     <key>tiles</key>
     <class>org.apache.velocity.tools.struts.TilesTool</class>
  </tool>
  <tool>
     <key>validator</key>
     <class>org.apache.velocity.tools.struts.ValidatorTool</class>
  </tool>
</toolbox>

===== payment.vm
<html lang="en-US">
  <head>
    <title>CCPAY</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <meta name="robots" content="noindex,nofollow">
    <link rel="stylesheet" type="text/css" href="/ccpay/pages/css/tccles.css">
  </head>
  <body class="body">
  	#errorMarkup()
    <form action="$link.setAction('Processing')" method="post">
      <table border="0" cellpadding="2" cellspacing="4" align="center" summary="Credit Card Information" width="100%">
        <tr> 
          <td class="head">Fee to be billed to your card</td>
          <td> $
            <input type="text" size="15" name="amount" value="$!paymentForm.amount" >
          </td>
        </tr>
      </table>
      <input type="submit" name="submit" />
    </form>
  </body>
</html>

===== processing.vm
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html lang="en-US">
  <head>
    <title>Processing Page.</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <meta name="robots" content="noindex,nofollow">
    <link rel="stylesheet" type="text/css" href="/ccpay/pages/css/tccles.css">
  </head>
  <body class="body">
    <div align="center"> <img src="/ccpay/pages/images/header.gif" alt="State of Tennessee Payment Option."> 
    </div>
    <div align="center"><br>
      <h4>Processing ...<br>
        Thank you for your patience<br>
        $!paymentForm.amount<br>
        <img src="https://www.tennesseeanytime.org/tnanytime/apps/processing.gif" alt="Showing Progress."></h4>
    </div>
  </body>
</html>

===== VM_global_library.vm
## Display all queued Struts errors
#macro (errorMarkup)
    #if ($errors.exist() )
        <ul>
        #foreach ($e in $errors.all )
            $e
        #end
        </ul>
    #end
#end






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


Re: Newbie needs help: Validator not working with Struts/Velocity

Posted by "Marino A. Jonsson" <ma...@hotmail.com>.
I see nothing wrong - the actions look fine and #errorMarkup() should take
care of displaying any form errors.  Did you model this after the validator
example in the velstruts appliction that comes with Velocity Tools 1.1-rc1?

cheers,
Marin�

<an...@leonidae.org> wrote in message
news:200403101754.i2AHspM31712@atmapp01.siteprotect.com...
> I'm fairly new to Struts, and have been trying to get my simple
> application to work - using Struts 1.1, Velocity 1.3.1, Velocity
> Tools 1.1-rc1, and Tomcat 4.1.29. The application (such as it is)
> works as far as presentation and workflow - but _isn't_ working is
> the Validator framework. I've spent the last day mining the web for
> help and haven't been able to progress at all...
>
> The validator files _are_ being loaded - I see them in the log
> files. And the rules/formset are being parsed - again, I see it in
> the log. However, when the form is submitted on the first page
> (payment.vm) and it goes to the second...no validation takes place.
> No errors are appearing in either the catalina.out or localhost
> log file. I have kicked up the log level to trace and still see
> nothing wrong - other than the validation doesn't seem to happen.
>
> Any help or suggestions would be GREATLY appreciated - I'm rather
> stuck at the moment. I'm sure its just some silly configuration
> or other error...
>
> I'm including all the relevant files inline below.
>
> Thank you very much
>
>   Andy Akins
>
> ====== web.xml
>
> <?xml version="1.0" encoding="ISO-8859-1"?>
> <!DOCTYPE web-app
>   PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
>   "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
> <web-app>
>   <display-name>CCPAY</display-name>
>   <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>
>     <init-param>
>       <param-name>debug</param-name>
>       <param-value>2</param-value>
>     </init-param>
>     <init-param>
>       <param-name>detail</param-name>
>       <param-value>2</param-value>
>     </init-param>
>     <init-param>
>       <param-name>validate</param-name>
>       <param-value>true</param-value>
>     </init-param>
>     <load-on-startup>2</load-on-startup>
>   </servlet>
>   <servlet>
>     <servlet-name>velocity</servlet-name>
>
<servlet-class>org.apache.velocity.tools.view.servlet.VelocityViewServlet</s
ervlet-class>
>     <init-param>
>       <param-name>org.apache.velocity.toolbox</param-name>
>       <param-value>/WEB-INF/toolbox.xml</param-value>
>     </init-param>
>     <init-param>
>       <param-name>org.apache.velocity.properties</param-name>
>       <param-value>/WEB-INF/velocity.properties</param-value>
>    </init-param>
>    <load-on-startup>10</load-on-startup>
>   </servlet>
>   <servlet-mapping>
>     <servlet-name>action</servlet-name>
>     <url-pattern>*.do</url-pattern>
>   </servlet-mapping>
>   <servlet-mapping>
>     <servlet-name>velocity</servlet-name>
>     <url-pattern>*.vm</url-pattern>
>   </servlet-mapping>
>   <welcome-file-list>
>     <welcome-file>index.html</welcome-file>
>   </welcome-file-list>
> </web-app>
>
> ===== struts-config.xml
> <?xml version="1.0" encoding="ISO-8859-1" ?>
> <!DOCTYPE struts-config PUBLIC
>           "-//Apache Software Foundation//DTD Struts Configuration
1.1//EN"
>           "http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd">
> <struts-config>
>   <form-beans>
>     <form-bean name="paymentForm"
type="org.apache.struts.validator.DynaValidatorForm">
>       <form-property name="amount" type="java.lang.String" initial="boo"
/>
>     </form-bean>
>   </form-beans>
>   <action-mappings>
>     <action path="/Payment"
>       type="org.apache.struts.actions.ForwardAction"
>       name="paymentForm"
>       validate="false"
>       parameter="/payment.vm"/>
>     <action path="/Processing"
>       type="org.apache.struts.actions.ForwardAction"
>       name="paymentForm"
>       input="/Payment.do"
>       validate="true"
>       parameter="/processing.vm"/>
>   </action-mappings>
>   <message-resources parameter="application" />
>   <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>
>
> ===== validation.xml - I'm using the standard validate-rules.xml
> <?xml version="1.0" encoding="ISO-8859-1" ?>
> <!DOCTYPE form-validation PUBLIC
>   "-//Apache Software Foundation//DTD Commons Validator Rules
Configuration 1.0//EN"
>   "http://jakarta.apache.org/commons/dtds/validator_1_0.dtd">
> <form-validation>
>   <formset>
>     <form name="paymentForm">
>       <field property="amount"
>         depends="required,email">
>         <msg name="email" key="errors.invalid"/>
>         <arg0 key="paymentForm.label.amount" />
>       </field>
>     </form>
>   </formset>
> </form-validation>
>
> ===== Toolbox.xml
> <?xml version="1.0"?>
>
> <toolbox>
>   <tool>
>      <key>link</key>
>      <class>org.apache.velocity.tools.struts.StrutsLinkTool</class>
>   </tool>
>   <tool>
>      <key>slink</key>
>      <class>org.apache.velocity.tools.struts.SecureLinkTool</class>
>   </tool>
>   <tool>
>      <key>text</key>
>      <class>org.apache.velocity.tools.struts.MessageTool</class>
>   </tool>
>   <tool>
>      <key>errors</key>
>      <class>org.apache.velocity.tools.struts.ErrorsTool</class>
>   </tool>
>   <tool>
>      <key>messages</key>
>      <class>org.apache.velocity.tools.struts.ActionMessagesTool</class>
>   </tool>
>   <tool>
>      <key>form</key>
>      <class>org.apache.velocity.tools.struts.FormTool</class>
>   </tool>
>   <tool>
>      <key>tiles</key>
>      <class>org.apache.velocity.tools.struts.TilesTool</class>
>   </tool>
>   <tool>
>      <key>validator</key>
>      <class>org.apache.velocity.tools.struts.ValidatorTool</class>
>   </tool>
> </toolbox>
>
> ===== payment.vm
> <html lang="en-US">
>   <head>
>     <title>CCPAY</title>
>     <meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
>     <meta name="robots" content="noindex,nofollow">
>     <link rel="stylesheet" type="text/css"
href="/ccpay/pages/css/tccles.css">
>   </head>
>   <body class="body">
>   #errorMarkup()
>     <form action="$link.setAction('Processing')" method="post">
>       <table border="0" cellpadding="2" cellspacing="4" align="center"
summary="Credit Card Information" width="100%">
>         <tr>
>           <td class="head">Fee to be billed to your card</td>
>           <td> $
>             <input type="text" size="15" name="amount"
value="$!paymentForm.amount" >
>           </td>
>         </tr>
>       </table>
>       <input type="submit" name="submit" />
>     </form>
>   </body>
> </html>
>
> ===== processing.vm
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
> <html lang="en-US">
>   <head>
>     <title>Processing Page.</title>
>     <meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
>     <meta name="robots" content="noindex,nofollow">
>     <link rel="stylesheet" type="text/css"
href="/ccpay/pages/css/tccles.css">
>   </head>
>   <body class="body">
>     <div align="center"> <img src="/ccpay/pages/images/header.gif"
alt="State of Tennessee Payment Option.">
>     </div>
>     <div align="center"><br>
>       <h4>Processing ...<br>
>         Thank you for your patience<br>
>         $!paymentForm.amount<br>
>         <img
src="https://www.tennesseeanytime.org/tnanytime/apps/processing.gif"
alt="Showing Progress."></h4>
>     </div>
>   </body>
> </html>
>
> ===== VM_global_library.vm
> ## Display all queued Struts errors
> #macro (errorMarkup)
>     #if ($errors.exist() )
>         <ul>
>         #foreach ($e in $errors.all )
>             $e
>         #end
>         </ul>
>     #end
> #end




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


Re: Newbie needs help: Validator not working with Struts/Velocity

Posted by Niall Pemberton <ni...@blueyonder.co.uk>.
You say "No errors are appearing in either the catalina.out or localhost log
file" - I don't think validator logs anything to those places and saying
that makes me think "what are you expecting to happen when validation
fails".

The normal course of events when validation fails is struts saves an
ActionErrors object in the request under a certain key
(org.apache.struts.action.ERROR) and forwards to the "input" parameter
defined for your action.

If you were using jsps you would then probably use the <html:errors> tag
which processes the stored ActionErrors and displays the error messages to
the user - I don't know velocity but presumably you could do something
similar.

Looking at your struts-config.xml, its your /Processing action which you are
expecting to validate - its input attribute is "/Payment.do" - this action
forwards to your velocity stuff "/payment.vm" - is there anything in
"/payment.vm" which displays the ActionErrors? To be honest your action
looks to be configured the wrong way round, I would have expected:

    <action path="/Processing"
      type="org.apache.struts.actions.ForwardAction"
      name="paymentForm"
      input="/processing.vm"
      validate="true"
      parameter="/Payment.do"/>

How about setting up a "validation errors page" in velocity and changing
your input parameter - that way if you get an validation error you should
see a different page. Something like...

    <action path="/Processing"
      type="org.apache.struts.actions.ForwardAction"
      name="paymentForm"
      input="/paymentErrors.vm"
      validate="true"
      parameter="/Payment.do"/>

Niall

----- Original Message ----- 
From: <an...@leonidae.org>
To: <st...@jakarta.apache.org>
Sent: Wednesday, March 10, 2004 5:54 PM
Subject: Newbie needs help: Validator not working with Struts/Velocity


I'm fairly new to Struts, and have been trying to get my simple
application to work - using Struts 1.1, Velocity 1.3.1, Velocity
Tools 1.1-rc1, and Tomcat 4.1.29. The application (such as it is)
works as far as presentation and workflow - but _isn't_ working is
the Validator framework. I've spent the last day mining the web for
help and haven't been able to progress at all...

The validator files _are_ being loaded - I see them in the log
files. And the rules/formset are being parsed - again, I see it in
the log. However, when the form is submitted on the first page
(payment.vm) and it goes to the second...no validation takes place.
No errors are appearing in either the catalina.out or localhost
log file. I have kicked up the log level to trace and still see
nothing wrong - other than the validation doesn't seem to happen.

Any help or suggestions would be GREATLY appreciated - I'm rather
stuck at the moment. I'm sure its just some silly configuration
or other error...

I'm including all the relevant files inline below.

Thank you very much

  Andy Akins

====== web.xml

<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE web-app
  PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
  "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
<web-app>
  <display-name>CCPAY</display-name>
  <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>
    <init-param>
      <param-name>debug</param-name>
      <param-value>2</param-value>
    </init-param>
    <init-param>
      <param-name>detail</param-name>
      <param-value>2</param-value>
    </init-param>
    <init-param>
      <param-name>validate</param-name>
      <param-value>true</param-value>
    </init-param>
    <load-on-startup>2</load-on-startup>
  </servlet>
  <servlet>
    <servlet-name>velocity</servlet-name>

<servlet-class>org.apache.velocity.tools.view.servlet.VelocityViewServlet</s
ervlet-class>
    <init-param>
      <param-name>org.apache.velocity.toolbox</param-name>
      <param-value>/WEB-INF/toolbox.xml</param-value>
    </init-param>
    <init-param>
      <param-name>org.apache.velocity.properties</param-name>
      <param-value>/WEB-INF/velocity.properties</param-value>
   </init-param>
   <load-on-startup>10</load-on-startup>
  </servlet>
  <servlet-mapping>
    <servlet-name>action</servlet-name>
    <url-pattern>*.do</url-pattern>
  </servlet-mapping>
  <servlet-mapping>
    <servlet-name>velocity</servlet-name>
    <url-pattern>*.vm</url-pattern>
  </servlet-mapping>
  <welcome-file-list>
    <welcome-file>index.html</welcome-file>
  </welcome-file-list>
</web-app>

===== struts-config.xml
<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE struts-config PUBLIC
          "-//Apache Software Foundation//DTD Struts Configuration 1.1//EN"
          "http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd">
<struts-config>
  <form-beans>
    <form-bean name="paymentForm"
type="org.apache.struts.validator.DynaValidatorForm">
      <form-property name="amount" type="java.lang.String" initial="boo" />
    </form-bean>
  </form-beans>
  <action-mappings>
    <action path="/Payment"
      type="org.apache.struts.actions.ForwardAction"
      name="paymentForm"
      validate="false"
      parameter="/payment.vm"/>
    <action path="/Processing"
      type="org.apache.struts.actions.ForwardAction"
      name="paymentForm"
      input="/Payment.do"
      validate="true"
      parameter="/processing.vm"/>
  </action-mappings>
  <message-resources parameter="application" />
  <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>

===== validation.xml - I'm using the standard validate-rules.xml
<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE form-validation PUBLIC
  "-//Apache Software Foundation//DTD Commons Validator Rules Configuration
1.0//EN"
  "http://jakarta.apache.org/commons/dtds/validator_1_0.dtd">
<form-validation>
  <formset>
    <form name="paymentForm">
      <field property="amount"
        depends="required,email">
        <msg name="email" key="errors.invalid"/>
        <arg0 key="paymentForm.label.amount" />
      </field>
    </form>
  </formset>
</form-validation>

===== Toolbox.xml
<?xml version="1.0"?>

<toolbox>
  <tool>
     <key>link</key>
     <class>org.apache.velocity.tools.struts.StrutsLinkTool</class>
  </tool>
  <tool>
     <key>slink</key>
     <class>org.apache.velocity.tools.struts.SecureLinkTool</class>
  </tool>
  <tool>
     <key>text</key>
     <class>org.apache.velocity.tools.struts.MessageTool</class>
  </tool>
  <tool>
     <key>errors</key>
     <class>org.apache.velocity.tools.struts.ErrorsTool</class>
  </tool>
  <tool>
     <key>messages</key>
     <class>org.apache.velocity.tools.struts.ActionMessagesTool</class>
  </tool>
  <tool>
     <key>form</key>
     <class>org.apache.velocity.tools.struts.FormTool</class>
  </tool>
  <tool>
     <key>tiles</key>
     <class>org.apache.velocity.tools.struts.TilesTool</class>
  </tool>
  <tool>
     <key>validator</key>
     <class>org.apache.velocity.tools.struts.ValidatorTool</class>
  </tool>
</toolbox>

===== payment.vm
<html lang="en-US">
  <head>
    <title>CCPAY</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <meta name="robots" content="noindex,nofollow">
    <link rel="stylesheet" type="text/css"
href="/ccpay/pages/css/tccles.css">
  </head>
  <body class="body">
  #errorMarkup()
    <form action="$link.setAction('Processing')" method="post">
      <table border="0" cellpadding="2" cellspacing="4" align="center"
summary="Credit Card Information" width="100%">
        <tr>
          <td class="head">Fee to be billed to your card</td>
          <td> $
            <input type="text" size="15" name="amount"
value="$!paymentForm.amount" >
          </td>
        </tr>
      </table>
      <input type="submit" name="submit" />
    </form>
  </body>
</html>

===== processing.vm
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html lang="en-US">
  <head>
    <title>Processing Page.</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <meta name="robots" content="noindex,nofollow">
    <link rel="stylesheet" type="text/css"
href="/ccpay/pages/css/tccles.css">
  </head>
  <body class="body">
    <div align="center"> <img src="/ccpay/pages/images/header.gif"
alt="State of Tennessee Payment Option.">
    </div>
    <div align="center"><br>
      <h4>Processing ...<br>
        Thank you for your patience<br>
        $!paymentForm.amount<br>
        <img
src="https://www.tennesseeanytime.org/tnanytime/apps/processing.gif"
alt="Showing Progress."></h4>
    </div>
  </body>
</html>

===== VM_global_library.vm
## Display all queued Struts errors
#macro (errorMarkup)
    #if ($errors.exist() )
        <ul>
        #foreach ($e in $errors.all )
            $e
        #end
        </ul>
    #end
#end






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




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