window.print method not working in ie browser
mycode:
<html>
<head>
<title>main</title>
</head>
<body>
<h1>Pop & print</h1>
<button onclick="pop();">Pop</button>
<script type="text/javascript">
var POP;
function pop() {
POP = window.open('', '', 'width=350,height=350');
POP.document.write(" message content message content message content message content message content <br/>"+"<a href='JavaScript:window.close()' style='float:right;'>Close</a><a href='JavaScript:window.print()' style='float:left; text-decoration:none;'><input type='button' value='Print this page' /></a>");
}
</script>
</body>
</html>
what am i doing wrong?