<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>测试Alert </title>
<script type="text/javascript" language="javascript">
function select1111(){
alert("1")
}
</script>
</HEAD>
<BODY>
<input type="text" value="点击这里" οnclick="select1111()" value="aaa" readonly="true" />
</BODY>
</html>
以上代码正常,将·函数改为select 不正常,出现。可能是函数名冲突导致
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>测试Alert </title>
<script type="text/javascript" language="javascript">
function select(){
alert("1")
}
</script>
</HEAD>
<BODY>
<input type="text" value="点击这里" οnclick="select()" value="aaa" readonly="true" />
</BODY>
</html>