sancha wrote:
> Hi,
> i am in a bit of a delima here.
> I need to submit an action through javascript
> so i used
>
> document.forms[0].action='/search.do?&submitaction=Add Minus'
> document.forms[0].submit();
>
>
> since i am working on struts then submitaction maps to through the
> action dispatcher.
>
> so where the action is mapperd as Add Minus
> it goes as Add%20%Minus because of the way i submitted. Is there any
> way i can make it go as Add Minus Please help
>
> Thanx in advance
> Sandip
Hi,
FIrstly:
document.forms[0].action='/search.do?&submitaction=Add Minus'
is wrong.
document.forms[0].action='/search.do?&submitaction=Add+Minus'
would be better.
But i would suggest another field in your form, call it submitaction, and
make it hidden.
Set the value for the hdeen field submitaction, and then just submit.
You are sending information by BOTH the Querystring and the POST.
Very confusing, at least for me, and probably for a few webservers too.
Regards,
Erwin Moller
|