Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsGeneralPHPASPPerlColdFusionFlashHTML, CSS, ScriptsBrowsers

Webmaster Forum / HTML, CSS, Scripts / JavaScript / March 2005



Tip: Looking for answers? Try searching our database.

Submit a form with Javascript

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
marco - 31 Mar 2005 20:26 GMT
Hi,

I have this problem : when I submit a Form with the usual
<html:form name="myForm" action="/myAction"
  type="org.apache.struts.validator.DynaValidatorActionForm">

.....
<input type="submit" name="action" value="Soumettre">
....

</form>

everything goes well.
If I try to submit the form with this code changes to prevent "double
submit"

<script language="javascript">

function onClickEventSubmit(elemID)
{
    elem = document.getElementById(elemID);
    elem.disabled = true;
    laForm = elem.form;
    laForm.submit();
}

....

<html:form name="myForm" action="/myAction"
  type="org.apache.struts.validator.DynaValidatorActionForm">
...
<input type="button" id="test3" name="action" value="Soumettre"
onclick="onClickEventSubmit('test3')>
....

</form>

I get the following error:
Request[/myAction] does not contain handler parameter named action

Note: I also tried
<input type="submit" id="test3" name="action" value="Soumettre"
onclick="onClickEventSubmit('test3')>

Any ideas?
Thanks
Marco
kaeli - 31 Mar 2005 22:20 GMT
> Hi,
>>
> I get the following error:
> Request[/myAction] does not contain handler parameter named action

This is a struts error, not really javascript-related per se.
You're best off asking in the com.lang.java.programmer group or at the sun
board.
http://forum.java.sun.com/index.jspa

Signature

--
~kaeli~
A man needs a mistress... just to break the monogamy.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.