<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>close()</title>
<script type="text/javascript">
var mywin = window.open("http://www.imooc.com");
var closewindow = confirm("是否关闭窗口");
if(closewindow = true){
mywin.close();
}
</script>
</head>
<body>
</body>
</html>
为什么我不管选择确定还是否定窗口最后都是关闭??