faqts : Computers : Programming : Languages : JavaScript : Language Core : Functions

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

28 of 84 people (33%) answered Yes
Recently 2 of 10 people (20%) answered Yes

Entry

how to call javascript function from jsp

Apr 25th, 2006 08:00
Shoaib Khan, dinesh albert,


JSP:
----------------------------------------------------------------------
<script language="javascript">

function submit()
{
   alert("Hello i am in Submit Function");
}

</script>

/*
now this is the submit button of your form. Just like this you can call
this on any available event of some other component
*/
<input name="submit" type="submit" value="Submit" onClick="submit()">
----------------------------------------------------------------------

Muhammad Shoaib Khan
01FB007
OPSTeC College of Computer Science
Lahore
Pakistan