日期:2014-05-16 浏览次数:20495 次
<html>
<head>
<script type="text/javascript" src="/jquery/jquery.js"></script>
<script type="text/javascript">
function displayInfo() {$("#Name").val("test");
}
function Info()
{
var y=$("#6").cells[1].innerHTML;
var x=$("#6").cells[1].innerHTML;
$("#ID").val(y)
$("#Name").val(x)
}
</script>
</head>
<body>
<h2>This is a heading</h2>
<p>This is a paragraph.</p>
<p>This is another paragraph.</p>
<button onclick="Info()" type="button">Click me</button>
<table width="100%">
<tr id="6" onmouseover="displayInfo()">
<td>6
</td>
<td>高考文库
</td>
</tr>
<tr id="7" onmouseover="displayInfo()">
<td>7
</td>
<td>中考文库
</td>
</tr>
<table/>
<br/>
<p>数字<input class="textbox" id="ID" name="Name" type="text" value="" /></P>
文库<input class="textbox" id="Name" name="Name" type="text" value="" />
</body>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js" type="text/javascript"></script>
<script type="text/javascript">
function displayInfo() {
$("#Name").val("test");
}
function Info() {