Here is the problem, I am learning DOM and am trying a few demo pages to learn I have created a page that holds 2 text boxes. I want to loop through the text boxes, grab the value and then display them some how. I dont care because I am just playing around. Can someone help me out. Thanks,
-T
-How important does a person have to be before they are considered assassinated instead of just murdered?
-Need more cow bell!!!
-T
Code:
<html>
<head>
<title>This is a test</title>
<script language="javascript">
function doSomting(idName)
{
var obj = document.getElementById(idName).value;
alert(obj);
}
function clearBox(idName)
{
document.getElementById(idName).value = "";
}
function infoMe()
{
var top = document.getElementById('topForm');
var list = top.getElementsByTagName('text');
alert(list.value);
}
</script>
</head>
<body>
<div id="topForm">
<input type="text" id="firstOne" value="I'm Here">
<input type="button" value="Clear" name="Clear" onclick="clearBox('firstOne')">
<br />
<input type="text" id="secondOne" value="">
<input type="button" value="Clear" name="Clear" onclick="clearBox('secondOne')">
<br />
</div>
<input type="button" value="Enter" name="Enter" onclick="doSomting('firstOne')">
<input type="button" value="WHAT" onclick="infoMe()">
</body>
</html>
-How important does a person have to be before they are considered assassinated instead of just murdered?
-Need more cow bell!!!