You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Victor CHEVALIER <vc...@avs-consulting.com> on 2002/09/16 15:29:15 UTC

find forward loose parameters in request

When I forward to the jsp, i can't retrieve attributes in request.
I also try with a single attribute, and I've got a 'null' value.

ACTION

saveErrors(request, errors);
return mapping.findForward("jspName");

JSP

<html:errors/>		-> nothing in the html page

Can anyone help me ?


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: find forward loose parameters in request

Posted by Andrew Hill <an...@gridnode.com>.
Is this action forward a redirecting forward? - If so parameters will be
lost.

-----Original Message-----
From: Victor CHEVALIER [mailto:vch@avs-consulting.com]
Sent: Monday, September 16, 2002 21:29
To: Struts Users Mailing List
Subject: find forward loose parameters in request


When I forward to the jsp, i can't retrieve attributes in request.
I also try with a single attribute, and I've got a 'null' value.

ACTION

saveErrors(request, errors);
return mapping.findForward("jspName");

JSP

<html:errors/>		-> nothing in the html page

Can anyone help me ?


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: find forward loose parameters in request

Posted by Victor CHEVALIER <vc...@avs-consulting.com>.
... After a large number of tests ...

My page is a frame :	MAIN contains TOP and BOTTOM
				in MAIN I've got the errors (<html:errors/>)
				in BOTTOM no more errors

Any idea ?


-----Message d'origine-----
De : Eddie Bush [mailto:ekbush@swbell.net]
Envoye : lundi 16 septembre 2002 17:46
A : Struts Users Mailing List
Objet : Re: find forward loose parameters in request


You've stumped me.  I think your data should be there (based off a lot
of inferences), provided this forward is contained in the action your
calling.  Hopefully someone else sees something I don't --
<playbook:punt/>.  Have you tried removing the redirect attribute
altogether?  The default is to forward, I believe ...

Regards,

Eddie

Victor CHEVALIER wrote:

>I've got this in my struts-config.xml
>
><forward name="jspName"
>	path="/jsp/jspName.jsp" redirect="false"/>
>
>And I use a mapping.findForward("jspName");
>
>Do I need more ?
>



--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: find forward loose parameters in request

Posted by Eddie Bush <ek...@swbell.net>.
You've stumped me.  I think your data should be there (based off a lot 
of inferences), provided this forward is contained in the action your 
calling.  Hopefully someone else sees something I don't -- 
<playbook:punt/>.  Have you tried removing the redirect attribute 
altogether?  The default is to forward, I believe ...

Regards,

Eddie

Victor CHEVALIER wrote:

>I've got this in my struts-config.xml
>
><forward name="jspName"
>	path="/jsp/jspName.jsp" redirect="false"/>
>
>And I use a mapping.findForward("jspName");
>
>Do I need more ?
>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: find forward loose parameters in request

Posted by Victor CHEVALIER <vc...@avs-consulting.com>.
I've got this in my struts-config.xml

<forward name="jspName"
	path="/jsp/jspName.jsp" redirect="false"/>

And I use a mapping.findForward("jspName");

Do I need more ?

-----Message d'origine-----
De : Eddie Bush [mailto:ekbush@swbell.net]
Envoye : lundi 16 septembre 2002 17:06
A : Struts Users Mailing List
Objet : Re: find forward loose parameters in request


You never said whether the forward you were using was set to redirect or
not.  That's quite important :-)  If it's set to redirect, and the form
bean is in request scope ... your values won't be there after the
forward (which is actually a redirect) because you'll start a new request.

Regards,

Eddie

Victor CHEVALIER wrote:

>Nothing works :
>It's like a new request was created. I put a String attribute in the
request
>but I can't acccess it (it prints 'null'). Before the 'return findForward'
>it's Ok, but in the jsp I've got nothing in the request.
>
>error.unknow exists and I can access it.
>



--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: find forward loose parameters in request

Posted by Eddie Bush <ek...@swbell.net>.
You never said whether the forward you were using was set to redirect or 
not.  That's quite important :-)  If it's set to redirect, and the form 
bean is in request scope ... your values won't be there after the 
forward (which is actually a redirect) because you'll start a new request.

Regards,

Eddie

Victor CHEVALIER wrote:

>Nothing works :
>It's like a new request was created. I put a String attribute in the request
>but I can't acccess it (it prints 'null'). Before the 'return findForward'
>it's Ok, but in the jsp I've got nothing in the request.
>
>error.unknow exists and I can access it.
>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: find forward loose parameters in request

Posted by Miguel Angel Mulero Martinez <mi...@mad.tecsidel.es>.
I don't know if it can help, but in jakarta, in the tags library, there's
the log tag library. It contains a tag that can print all the beans in a
specified scope. Try it, maybe it can help.



-----Mensaje original-----
De: Victor CHEVALIER [mailto:vch@avs-consulting.com]
Enviado el: lunes, 16 de septiembre de 2002 16:46
Para: Struts Users Mailing List
Asunto: RE: find forward loose parameters in request

Nothing works :
It's like a new request was created. I put a String attribute in the request
but I can't acccess it (it prints 'null'). Before the 'return findForward'
it's Ok, but in the jsp I've got nothing in the request.

error.unknow exists and I can access it.

-----Message d'origine-----
De : Miguel Angel Mulero Martinez
[mailto:miguel-angel.mulero@mad.tecsidel.es]
Envoyé : lundi 16 septembre 2002 16:30
À : Struts Users Mailing List
Objet : RE: find forward loose parameters in request


Hi,

I don't know if this could help, but I use:

errors.add("insert", new ActionError("error.unknown"));

I use an String ("insert") to refer to this error, not a constant. Try it to
see what happen. Try to print too the "error.unknown" message in a JSP, to
make sure that it is accesible.

Miguel

-----Mensaje original-----
De: Victor CHEVALIER [mailto:vch@avs-consulting.com]
Enviado el: lunes, 16 de septiembre de 2002 15:57
Para: Struts Users Mailing List
Asunto: RE: find forward loose parameters in request

These are the lines of the 'error segment' :

ActionErrors errors = new ActionErrors();
errors.add(ActionErrors.GLOBAL_ERROR, new ActionError("error.unknown"));
saveErrors(request, errors);
return mapping.findForward("jspName");

-----Message d'origine-----
De : Miguel Angel Mulero Martinez
[mailto:miguel-angel.mulero@mad.tecsidel.es]
Envoyé : lundi 16 septembre 2002 15:42
À : Struts Users Mailing List
Objet : RE: find forward loose parameters in request


The two line are correct, and I've used it. The only thing that can fail is
the creation of errors. Can you put the lines where you create an error?

-----Mensaje original-----
De: Victor CHEVALIER [mailto:vch@avs-consulting.com]
Enviado el: lunes, 16 de septiembre de 2002 15:29
Para: Struts Users Mailing List
Asunto: find forward loose parameters in request

When I forward to the jsp, i can't retrieve attributes in request.
I also try with a single attribute, and I've got a 'null' value.

ACTION

saveErrors(request, errors);
return mapping.findForward("jspName");

JSP

<html:errors/>          -> nothing in the html page

Can anyone help me ?


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: find forward loose parameters in request

Posted by phpsurf <ph...@ifrance.com>.
don't you have set the 'redirect' attribute to 'true' in your action
<forward> ?
can you send the action mapping you have configured for this action in your
struts-config.xml ?


> -----Original Message-----
> From: Victor CHEVALIER [mailto:vch@avs-consulting.com]
> Sent: lundi 16 septembre 2002 16:46
> To: Struts Users Mailing List
> Subject: RE: find forward loose parameters in request
>
>
> Nothing works :
> It's like a new request was created. I put a String attribute in
> the request
> but I can't acccess it (it prints 'null'). Before the 'return findForward'
> it's Ok, but in the jsp I've got nothing in the request.
>
> error.unknow exists and I can access it.
>
> -----Message d'origine-----
> De : Miguel Angel Mulero Martinez
> [mailto:miguel-angel.mulero@mad.tecsidel.es]
> Envoyé : lundi 16 septembre 2002 16:30
> À : Struts Users Mailing List
> Objet : RE: find forward loose parameters in request
>
>
> Hi,
>
> I don't know if this could help, but I use:
>
> errors.add("insert", new ActionError("error.unknown"));
>
> I use an String ("insert") to refer to this error, not a
> constant. Try it to
> see what happen. Try to print too the "error.unknown" message in a JSP, to
> make sure that it is accesible.
>
> Miguel
>
> -----Mensaje original-----
> De: Victor CHEVALIER [mailto:vch@avs-consulting.com]
> Enviado el: lunes, 16 de septiembre de 2002 15:57
> Para: Struts Users Mailing List
> Asunto: RE: find forward loose parameters in request
>
> These are the lines of the 'error segment' :
>
> ActionErrors errors = new ActionErrors();
> errors.add(ActionErrors.GLOBAL_ERROR, new ActionError("error.unknown"));
> saveErrors(request, errors);
> return mapping.findForward("jspName");
>
> -----Message d'origine-----
> De : Miguel Angel Mulero Martinez
> [mailto:miguel-angel.mulero@mad.tecsidel.es]
> Envoyé : lundi 16 septembre 2002 15:42
> À : Struts Users Mailing List
> Objet : RE: find forward loose parameters in request
>
>
> The two line are correct, and I've used it. The only thing that
> can fail is
> the creation of errors. Can you put the lines where you create an error?
>
> -----Mensaje original-----
> De: Victor CHEVALIER [mailto:vch@avs-consulting.com]
> Enviado el: lunes, 16 de septiembre de 2002 15:29
> Para: Struts Users Mailing List
> Asunto: find forward loose parameters in request
>
> When I forward to the jsp, i can't retrieve attributes in request.
> I also try with a single attribute, and I've got a 'null' value.
>
> ACTION
>
> saveErrors(request, errors);
> return mapping.findForward("jspName");
>
> JSP
>
> <html:errors/>          -> nothing in the html page
>
> Can anyone help me ?
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


________________________________________________________________
Etudiant: Wanadoo t'offre le Pack eXtense Haut Débit soit 150,92 euros d'économies !
Et pour 1 euro de plus, reçois le CD-ROM du jeu Dark Age of Camelot
+ 1 mois de jeu en réseau offert ! 
Clique ici : http://www.ifrance.com/_reloc/mail.etudiant 


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: find forward loose parameters in request

Posted by Victor CHEVALIER <vc...@avs-consulting.com>.
Nothing works :
It's like a new request was created. I put a String attribute in the request
but I can't acccess it (it prints 'null'). Before the 'return findForward'
it's Ok, but in the jsp I've got nothing in the request.

error.unknow exists and I can access it.

-----Message d'origine-----
De : Miguel Angel Mulero Martinez
[mailto:miguel-angel.mulero@mad.tecsidel.es]
Envoyé : lundi 16 septembre 2002 16:30
À : Struts Users Mailing List
Objet : RE: find forward loose parameters in request


Hi,

I don't know if this could help, but I use:

errors.add("insert", new ActionError("error.unknown"));

I use an String ("insert") to refer to this error, not a constant. Try it to
see what happen. Try to print too the "error.unknown" message in a JSP, to
make sure that it is accesible.

Miguel

-----Mensaje original-----
De: Victor CHEVALIER [mailto:vch@avs-consulting.com]
Enviado el: lunes, 16 de septiembre de 2002 15:57
Para: Struts Users Mailing List
Asunto: RE: find forward loose parameters in request

These are the lines of the 'error segment' :

ActionErrors errors = new ActionErrors();
errors.add(ActionErrors.GLOBAL_ERROR, new ActionError("error.unknown"));
saveErrors(request, errors);
return mapping.findForward("jspName");

-----Message d'origine-----
De : Miguel Angel Mulero Martinez
[mailto:miguel-angel.mulero@mad.tecsidel.es]
Envoyé : lundi 16 septembre 2002 15:42
À : Struts Users Mailing List
Objet : RE: find forward loose parameters in request


The two line are correct, and I've used it. The only thing that can fail is
the creation of errors. Can you put the lines where you create an error?

-----Mensaje original-----
De: Victor CHEVALIER [mailto:vch@avs-consulting.com]
Enviado el: lunes, 16 de septiembre de 2002 15:29
Para: Struts Users Mailing List
Asunto: find forward loose parameters in request

When I forward to the jsp, i can't retrieve attributes in request.
I also try with a single attribute, and I've got a 'null' value.

ACTION

saveErrors(request, errors);
return mapping.findForward("jspName");

JSP

<html:errors/>          -> nothing in the html page

Can anyone help me ?


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: find forward loose parameters in request

Posted by Miguel Angel Mulero Martinez <mi...@mad.tecsidel.es>.
Hi,

I don't know if this could help, but I use:

errors.add("insert", new ActionError("error.unknown"));

I use an String ("insert") to refer to this error, not a constant. Try it to
see what happen. Try to print too the "error.unknown" message in a JSP, to
make sure that it is accesible.

Miguel

-----Mensaje original-----
De: Victor CHEVALIER [mailto:vch@avs-consulting.com]
Enviado el: lunes, 16 de septiembre de 2002 15:57
Para: Struts Users Mailing List
Asunto: RE: find forward loose parameters in request

These are the lines of the 'error segment' :

ActionErrors errors = new ActionErrors();
errors.add(ActionErrors.GLOBAL_ERROR, new ActionError("error.unknown"));
saveErrors(request, errors);
return mapping.findForward("jspName");

-----Message d'origine-----
De : Miguel Angel Mulero Martinez
[mailto:miguel-angel.mulero@mad.tecsidel.es]
Envoyé : lundi 16 septembre 2002 15:42
À : Struts Users Mailing List
Objet : RE: find forward loose parameters in request


The two line are correct, and I've used it. The only thing that can fail is
the creation of errors. Can you put the lines where you create an error?

-----Mensaje original-----
De: Victor CHEVALIER [mailto:vch@avs-consulting.com]
Enviado el: lunes, 16 de septiembre de 2002 15:29
Para: Struts Users Mailing List
Asunto: find forward loose parameters in request

When I forward to the jsp, i can't retrieve attributes in request.
I also try with a single attribute, and I've got a 'null' value.

ACTION

saveErrors(request, errors);
return mapping.findForward("jspName");

JSP

<html:errors/>          -> nothing in the html page

Can anyone help me ?


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: find forward loose parameters in request

Posted by Victor CHEVALIER <vc...@avs-consulting.com>.
These are the lines of the 'error segment' :

ActionErrors errors = new ActionErrors();
errors.add(ActionErrors.GLOBAL_ERROR, new ActionError("error.unknown"));
saveErrors(request, errors);
return mapping.findForward("jspName");

-----Message d'origine-----
De : Miguel Angel Mulero Martinez
[mailto:miguel-angel.mulero@mad.tecsidel.es]
Envoyé : lundi 16 septembre 2002 15:42
À : Struts Users Mailing List
Objet : RE: find forward loose parameters in request


The two line are correct, and I've used it. The only thing that can fail is
the creation of errors. Can you put the lines where you create an error?

-----Mensaje original-----
De: Victor CHEVALIER [mailto:vch@avs-consulting.com]
Enviado el: lunes, 16 de septiembre de 2002 15:29
Para: Struts Users Mailing List
Asunto: find forward loose parameters in request

When I forward to the jsp, i can't retrieve attributes in request.
I also try with a single attribute, and I've got a 'null' value.

ACTION

saveErrors(request, errors);
return mapping.findForward("jspName");

JSP

<html:errors/>          -> nothing in the html page

Can anyone help me ?


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: find forward loose parameters in request

Posted by Miguel Angel Mulero Martinez <mi...@mad.tecsidel.es>.
The two line are correct, and I've used it. The only thing that can fail is
the creation of errors. Can you put the lines where you create an error?

-----Mensaje original-----
De: Victor CHEVALIER [mailto:vch@avs-consulting.com]
Enviado el: lunes, 16 de septiembre de 2002 15:29
Para: Struts Users Mailing List
Asunto: find forward loose parameters in request

When I forward to the jsp, i can't retrieve attributes in request.
I also try with a single attribute, and I've got a 'null' value.

ACTION

saveErrors(request, errors);
return mapping.findForward("jspName");

JSP

<html:errors/>          -> nothing in the html page

Can anyone help me ?


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>