return "Iam Ramya";
<HEAD><TITLE> Example of onClick Event Handler</TITLE>
<BODY BGCOLOR="FFFFFF" TEXT="000000">
<INPUT TYPE="button" VALUE="Click Here" onClick="callJsp()">
You can make calls to the server to do stuff, but I doubt that's what you want.
i have one doubt in ur code.
how to pass params to jsp method from js.
in above code shows error . how to pass name params to jsp method?.
You can't (as I said 18 months ago).
"name" exists on the client.
hai() exists on the server.
Unless your client makes a call (say an Ajax call) to the server then they will never meet.