Hi,
i have started to learn javascript.
To run javascript.. browser window and notepad is enough
or i need to load java s/w
also, i'm not getting output for this coding..can any one help me pls???
<!DOcTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>first java script example</title>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1" />
<script type="text/javascript">
function calculateArea(Width,Height)
{
area=Width*Height
return (area);
}
</script>
</head>
<body>
<form name="frmArea action="#">
enter the width and height:<br/>
width:<input type="text" name="txtWidth" size=5 /><br/>
height:<input type="text" name="txtHeight" size=5 /><br/>
<input type="button" value="calculate area" onclick="alert(calculateArea(document.frmArea.txtWidth.value,document.frmArea.txtHeight.value))"/>
</form>
</body>
</html>