编辑下面的代码:【加编码】
<html> <head> <script> function show_popup() { var p=window.createPopup(); var pbody=p.document.body; pbody.style.backgroundColor="lime"; pbody.style.border="solid black 1px"; pbody.innerHTML="This is a pop-up! Click outside the pop-up to close."; p.show(150,150,200,50,document.body); } </script> </head> <body> <button onclick="show_popup()">Show pop-up!</button> <p><b>Note:</b> The createPopup() method only works in IE!</p> </body> </html>
结果: 【此窗口】 帮助?
Try it Yourself - © 自强学堂