struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "jignesh(india)" <>
Subject Automatic form submission using javascript in struts2
Date Fri, 07 Dec 2007 05:25:35 GMT


I want to submit my <form automatically from resulted jsp in struts2 using
javascript at the time of page loaded.
I have tried ordinary javascript but it is not

Can anyone help me why it isn't working.

My code:-

<form name="secureResponsefrm" method="post"
action="http://24.practice.jad/www_new/merchantRespo.php" id="frmid">
	<s:hidden name="serviceid"/>
	<s:hidden name="customerid"/>	
	<s:submit name="submit" value="Submit" id="submit"/>

<script type="text/javascript"><!--

Each time page loaded it calls the script but giving javascript error

document.forms[0].submit is not a function

Thanks in advanced.
View this message in context:
Sent from the Struts - User mailing list archive at

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message