这个为什么不行呢
<input id= "ww " checked type= "checkbox " onload= "javascript:alert(); "/>
这个没反应
我想在这个checkbox加载完之后执行一个function
------解决方案-------------------- <input id= "ww " checked= "checked " type= "checkbox " onmousemove= "javascript:alert( 'ok ');this.onmousemove=null; ">
------解决方案--------------------如果程序允许的话可以在checkbox后跟一张图片,隐藏掉就OK了。
<input id= "ww " checked type= "checkbox "/> <img src= "必须指定一个图片 " onload= "alert( ' ') " style= "display:none " />
要不就在checkbox后跟一段脚本直接执行相关函数,变通点,总有解决办法的。
<input id= "ww " checked type= "checkbox "/>
<script language= "javascript ">
//do something
</script>
------解决方案-------------------- <html>
<head>
<title> </title>
<script language= "javascript " type= "text/javascript ">
function test()
{
alert( "ok ");
setTimeout( "a() ",2000)//两秒执行
}
function a()
{
}
</script>
</head>
<body>
<input name= "c " id= "c " type= "checkbox " value= "test " onmousemove= "test() " onmousemove= "null ">
</body>
</html>