Friday, 20 May 2011

pass value from html to java script

<HTML>
<HEAD>
<TITLE> Pass value from HTML to JavaScript </TITLE>
<script language="JavaScript" >
function hello(name)
{
         alert("Hello! "+name);
}
</script>
</HEAD>
<BODY>
Get Hello Message<br>
<input type="button" onclick='hello("sateesh");' value="Click"/>
</BODY>
</HTML>
Post a Comment