为什么这样写,这样也可以呀
<script>
function ch()
{
window.location.href = "test.htm"
}
</script>
<body><input type="button" onclick="ch();">
<script>
function ch()
{
window.location.href = "test.htm"
}
</script>
<body><input type="button" onclick="ch();">
{
document.all['aaa'].click()
}
</script>
<body>
<a href="test.html" ID=aaa>click me</a>
<input type="button" onclick="ch();">