0

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?

Edited by diafol: Post to the correct forum

3
Contributors
2
Replies
4
Views
5 Years
Discussion Span
Last Post by dany12
0

It's not your fault, IE uses a lot of different methods, I personally do not like IE because of how many workarounds one would have to code. IE in my opinion is a major fail.
Please, for the sake of humankind, don't use IE.

0

Better still use jquery to make ie users happy and yorself 100% compatibility with all browser the next best thing

Look at this and than say jquery rules Click Here

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.