You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by f f <ph...@yahoo.com> on 2004/02/03 16:51:06 UTC

An Action doesn't work as expected

Hi gurus,

I'm just learning to develop web application with
Struts. All Action works well,
except SubmitCustomerAction. I've tried to find the
problem but I can't find it so far.

Here is some relevant information

on jsp page :

<html:form action="/submitCustomer" focus="name"
	onsubmit="return
validateCustomerRegistrationForm(this);">
	<table>
		<tr>
		<!-- more html and jsp tags -->
</html:form>

on struts-config.xml :

  <form-beans>
    <form-bean
      name="CustomerRegistrationForm"
      type="proj.web.form.CustomerRegistrationForm"
    />
    
    <!-- more form-beans -->
 	</form-beans>

 	<action-mappings>
    <action
      path="/submitCustomer"
      type="proj.web.action.SubmitCustomerAction"
      name="CustomerRegistrationForm"
      scope="request"
      unknown="false"
      validate="true"
    >
      <forward
        name="success"
        path="/order/orderSuccess.jsp"
        redirect="false"
      />
      <forward
        name="failure"
        path="/common/error.jsp"
        redirect="false"
      />
      <forward
        name="trySubmitOrder"
        path="/trySubmitOrder.do"
        redirect="false"
      />
    </action>
    <!-- more actions -->
 	</action-mappings>

tomcat gives this error :
The server encountered an internal error (No input
attribute for mapping path /submitCustomer)
that prevented it from fulfilling this request.

and from jboss server.log:
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  Looking for
ActionForm bean instance in scope 'request' under
attribute key 'CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  Creating new
ActionForm instance of type
'proj.web.form.CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  -->
proj.web.form.CustomerRegistrationForm@95ddb5
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor]  Storing
ActionForm bean instance in scope 'request' under
attribute key 'CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor] 
Populating bean properties from this request
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor] 
Validating input form properties
2004-02-03 22:01:52,390 DEBUG
[org.apache.struts.util.PropertyMessageResources]
getMessage(en,customer.email)
2004-02-03 22:01:52,390 DEBUG
[org.apache.struts.util.PropertyMessageResources]
loadLocale(en)
2004-02-03 22:01:52,431 DEBUG
[org.apache.struts.action.RequestProcessor]  
Validation failed but no input form available

I use Jboss 3.2.2,Apache-Tomcat
4.1.27-LE-jdk14,Jakarta-Struts 1.1 and JDK 1.4.0-b92.

Something wrong ? Please help.

Thanks for your help.
Fredrich.


__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free web site building tool. Try it!
http://webhosting.yahoo.com/ps/sb/

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


RE: An Action doesn't work as expected

Posted by Ramachandran <ra...@summitworks.com>.
In your Action mapping tag,

                    u have to give the input="/xx.jsp" to redirect the error
to your application. then only it will work.


-----Original Message-----
From: f f [mailto:phipeapixh@yahoo.com]
Sent: Tuesday, February 03, 2004 9:21 PM
To: struts-user@jakarta.apache.org
Subject: An Action doesn't work as expected


Hi gurus,

I'm just learning to develop web application with
Struts. All Action works well,
except SubmitCustomerAction. I've tried to find the
problem but I can't find it so far.

Here is some relevant information

on jsp page :

<html:form action="/submitCustomer" focus="name"
	onsubmit="return
validateCustomerRegistrationForm(this);">
	<table>
		<tr>
		<!-- more html and jsp tags -->
</html:form>

on struts-config.xml :

  <form-beans>
    <form-bean
      name="CustomerRegistrationForm"
      type="proj.web.form.CustomerRegistrationForm"
    />

    <!-- more form-beans -->
 	</form-beans>

 	<action-mappings>
    <action
      path="/submitCustomer"
      type="proj.web.action.SubmitCustomerAction"
      name="CustomerRegistrationForm"
      scope="request"
      unknown="false"
      validate="true"
    >
      <forward
        name="success"
        path="/order/orderSuccess.jsp"
        redirect="false"
      />
      <forward
        name="failure"
        path="/common/error.jsp"
        redirect="false"
      />
      <forward
        name="trySubmitOrder"
        path="/trySubmitOrder.do"
        redirect="false"
      />
    </action>
    <!-- more actions -->
 	</action-mappings>

tomcat gives this error :
The server encountered an internal error (No input
attribute for mapping path /submitCustomer)
that prevented it from fulfilling this request.

and from jboss server.log:
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  Looking for
ActionForm bean instance in scope 'request' under
attribute key 'CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  Creating new
ActionForm instance of type
'proj.web.form.CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  -->
proj.web.form.CustomerRegistrationForm@95ddb5
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor]  Storing
ActionForm bean instance in scope 'request' under
attribute key 'CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor]
Populating bean properties from this request
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor]
Validating input form properties
2004-02-03 22:01:52,390 DEBUG
[org.apache.struts.util.PropertyMessageResources]
getMessage(en,customer.email)
2004-02-03 22:01:52,390 DEBUG
[org.apache.struts.util.PropertyMessageResources]
loadLocale(en)
2004-02-03 22:01:52,431 DEBUG
[org.apache.struts.action.RequestProcessor]
Validation failed but no input form available

I use Jboss 3.2.2,Apache-Tomcat
4.1.27-LE-jdk14,Jakarta-Struts 1.1 and JDK 1.4.0-b92.

Something wrong ? Please help.

Thanks for your help.
Fredrich.


__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free web site building tool. Try it!
http://webhosting.yahoo.com/ps/sb/

---------------------------------------------------------------------
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


RE: An Action doesn't work as expected

Posted by Ramachandran <ra...@summitworks.com>.
Hi,

       Who says, u give likr this. Then it will surely work. Bcos it finds
any errors while processing action, it will navigate to this input file.

<action path="/LoginAction" type="com.summit.LoginAction" name="Login"
scope="request" input="/login.jsp" validate="true"><forward name="success"
path="/Homes.jsp" redirect="false" /></action>

-----Original Message-----
From: Matthew J. Vincent [mailto:vincent@cs.usm.maine.edu]
Sent: Tuesday, February 03, 2004 9:25 PM
To: Struts Users Mailing List
Subject: RE: An Action doesn't work as expected


You don't have the input attribute in your action mapping.

...
    <action
      path="/submitCustomer"
      type="proj.web.action.SubmitCustomerAction"
      name="CustomerRegistrationForm"
      input="????????????????????????????????????????????????????????????"
      scope="request"
      unknown="false"
      validate="true"
    >
...


HTH.

Matt



-----Original Message-----
From: f f [mailto:phipeapixh@yahoo.com]
Sent: Tuesday, February 03, 2004 10:51 AM
To: struts-user@jakarta.apache.org
Subject: An Action doesn't work as expected


Hi gurus,

I'm just learning to develop web application with
Struts. All Action works well,
except SubmitCustomerAction. I've tried to find the
problem but I can't find it so far.

Here is some relevant information

on jsp page :

<html:form action="/submitCustomer" focus="name"
	onsubmit="return
validateCustomerRegistrationForm(this);">
	<table>
		<tr>
		<!-- more html and jsp tags -->
</html:form>

on struts-config.xml :

  <form-beans>
    <form-bean
      name="CustomerRegistrationForm"
      type="proj.web.form.CustomerRegistrationForm"
    />

    <!-- more form-beans -->
 	</form-beans>

 	<action-mappings>
    <action
      path="/submitCustomer"
      type="proj.web.action.SubmitCustomerAction"
      name="CustomerRegistrationForm"
      scope="request"
      unknown="false"
      validate="true"
    >
      <forward
        name="success"
        path="/order/orderSuccess.jsp"
        redirect="false"
      />
      <forward
        name="failure"
        path="/common/error.jsp"
        redirect="false"
      />
      <forward
        name="trySubmitOrder"
        path="/trySubmitOrder.do"
        redirect="false"
      />
    </action>
    <!-- more actions -->
 	</action-mappings>

tomcat gives this error :
The server encountered an internal error (No input
attribute for mapping path /submitCustomer)
that prevented it from fulfilling this request.

and from jboss server.log:
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  Looking for
ActionForm bean instance in scope 'request' under
attribute key 'CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  Creating new
ActionForm instance of type
'proj.web.form.CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  -->
proj.web.form.CustomerRegistrationForm@95ddb5
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor]  Storing
ActionForm bean instance in scope 'request' under
attribute key 'CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor]
Populating bean properties from this request
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor]
Validating input form properties
2004-02-03 22:01:52,390 DEBUG
[org.apache.struts.util.PropertyMessageResources]
getMessage(en,customer.email)
2004-02-03 22:01:52,390 DEBUG
[org.apache.struts.util.PropertyMessageResources]
loadLocale(en)
2004-02-03 22:01:52,431 DEBUG
[org.apache.struts.action.RequestProcessor]
Validation failed but no input form available

I use Jboss 3.2.2,Apache-Tomcat
4.1.27-LE-jdk14,Jakarta-Struts 1.1 and JDK 1.4.0-b92.

Something wrong ? Please help.

Thanks for your help.
Fredrich.


__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free web site building tool. Try it!
http://webhosting.yahoo.com/ps/sb/

---------------------------------------------------------------------
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



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


RE: An Action doesn't work as expected

Posted by "Matthew J. Vincent" <vi...@cs.usm.maine.edu>.
You don't have the input attribute in your action mapping.

...
    <action
      path="/submitCustomer"
      type="proj.web.action.SubmitCustomerAction"
      name="CustomerRegistrationForm"
      input="????????????????????????????????????????????????????????????"
      scope="request"
      unknown="false"
      validate="true"
    >
...


HTH.

Matt



-----Original Message-----
From: f f [mailto:phipeapixh@yahoo.com]
Sent: Tuesday, February 03, 2004 10:51 AM
To: struts-user@jakarta.apache.org
Subject: An Action doesn't work as expected


Hi gurus,

I'm just learning to develop web application with
Struts. All Action works well,
except SubmitCustomerAction. I've tried to find the
problem but I can't find it so far.

Here is some relevant information

on jsp page :

<html:form action="/submitCustomer" focus="name"
	onsubmit="return
validateCustomerRegistrationForm(this);">
	<table>
		<tr>
		<!-- more html and jsp tags -->
</html:form>

on struts-config.xml :

  <form-beans>
    <form-bean
      name="CustomerRegistrationForm"
      type="proj.web.form.CustomerRegistrationForm"
    />
    
    <!-- more form-beans -->
 	</form-beans>

 	<action-mappings>
    <action
      path="/submitCustomer"
      type="proj.web.action.SubmitCustomerAction"
      name="CustomerRegistrationForm"
      scope="request"
      unknown="false"
      validate="true"
    >
      <forward
        name="success"
        path="/order/orderSuccess.jsp"
        redirect="false"
      />
      <forward
        name="failure"
        path="/common/error.jsp"
        redirect="false"
      />
      <forward
        name="trySubmitOrder"
        path="/trySubmitOrder.do"
        redirect="false"
      />
    </action>
    <!-- more actions -->
 	</action-mappings>

tomcat gives this error :
The server encountered an internal error (No input
attribute for mapping path /submitCustomer)
that prevented it from fulfilling this request.

and from jboss server.log:
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  Looking for
ActionForm bean instance in scope 'request' under
attribute key 'CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  Creating new
ActionForm instance of type
'proj.web.form.CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.util.RequestUtils]  -->
proj.web.form.CustomerRegistrationForm@95ddb5
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor]  Storing
ActionForm bean instance in scope 'request' under
attribute key 'CustomerRegistrationForm'
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor] 
Populating bean properties from this request
2004-02-03 22:01:52,180 DEBUG
[org.apache.struts.action.RequestProcessor] 
Validating input form properties
2004-02-03 22:01:52,390 DEBUG
[org.apache.struts.util.PropertyMessageResources]
getMessage(en,customer.email)
2004-02-03 22:01:52,390 DEBUG
[org.apache.struts.util.PropertyMessageResources]
loadLocale(en)
2004-02-03 22:01:52,431 DEBUG
[org.apache.struts.action.RequestProcessor]  
Validation failed but no input form available

I use Jboss 3.2.2,Apache-Tomcat
4.1.27-LE-jdk14,Jakarta-Struts 1.1 and JDK 1.4.0-b92.

Something wrong ? Please help.

Thanks for your help.
Fredrich.


__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free web site building tool. Try it!
http://webhosting.yahoo.com/ps/sb/

---------------------------------------------------------------------
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