the command object on POST requests?
the command object on POST requests?
cheers,
Lili
Is overriding isFormSubmission what you want?
I don't think overriding isFormSubmission will help me. Because my POST request IS a form submission and I still want to bind the form values to my command but not the query string parameters. The functionality I am looking for is
if(request == GET)
bind querystring parameters to my command
if(request == POST)
bind ONLY post parametes to my commnd
cheers,
Lili
I guess katentim meant that isFormSubmission would be exactly where you could put the branch logic you just described.
--Jing Xue
Unless I am missing something. As far as I know overriding isFormSubmission is not going to work.
1) isFormSubmission does not take a (Object command) argument so I cannot do the binding myself in isFormSubmission as it was suggested.
2) Overriding it to return a false when I recieve a POST request will cause BOTH post and querystring parameters not to be binded to the command object. I do want the post parameters to be binded to the command object just NOT the querystring parameters.
Any other ideas out there?
cheers,
Lili
I think I know what you mean.Because my POST request IS a form submission
AFAIK, this can't be done out of the box. Why not change the query string?
I was able to get around this problem by specifying an "action" attribute for my form that does not include the querystring parameters <form action="/path/file.html">. So now the request object resulting from the POST does not include the querystring parameters.
I had not included an action attribute before because I was using tiles. So the requestUrl defaulted to the current URL which included the querystring parameters.
cheers,
Lili