Dear Sir,
In a simple form there are two text field and one submit button (button2).I want to perform some asp codeed work (here for example writing date for example...).Which should run on click of button1 withought submitting the form.
What is the best method to do so.?
1. One way could be write javascript function on onclick event of button1,but how to write it...
Do update this code for my learning please
Regards
Om Prakash
Code:
<%@ Language=VBScript %>
<HTML>
<HEAD>
</HEAD>
<BODY>
<form method = post action="xyz.asp">
<P> </P>
<P>
Text1 <INPUT id=text1 style="LEFT: 17px; WIDTH: 158px; TOP: 16px; HEIGHT: 22px" size=19 name=text1><INPUT id=button1 style="LEFT: 215px; WIDTH: 64px; TOP: 15px; HEIGHT: 24px" type=button size=22 value=Button1 name=button1> <br>
Text2 <INPUT id=text2 style="LEFT: 56px; TOP: 59px" name=text2><INPUT id=button2 type=submit value=Button2 name=button2></P></form></BODY></HTML>
</form>
<%
Response.Write now()
%>
</body>
</head>
</html>
om prakash kumar