我这个点击按钮没反应是怎么回事啊?
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<script type="text/javascript">
function name(){
var mynum=confirm("你抽烟吗?");
if(mynum==true)
{
document.write("好吧 少抽点");
}
else{
document.write("不抽就好");
}
}
</script>
</head>
<body>
<input type="button" name"myname" onClick="name()" value="点击我">
</body>
</html>