读书人

运用 showModalDialog

发布时间: 2012-11-06 14:07:00 作者: rapoo

使用 showModalDialog

Code example: http://samples.msdn.microsoft.com/workshop/samples/author/dhtml/refs/showModalDialog2.htm

Linked from the following button is an extended version of the above script, which demonstrates many of the features available for creating a custom dialog box.

Code example: http://samples.msdn.microsoft.com/workshop/samples/author/dhtml/refs/showModalDialog.htm

Neither modal nor modeless HTML dialog boxes support text selection or the standard shortcut menu for copy operations; however, you can imitate this functionality by using script with TextRange objects and event handlers for onmousedown and onmousemove, as in the following example.

Code example: http://samples.msdn.microsoft.com/workshop/samples/author/dhtml/refs/showModalDialogLaunch.htm

?

使用dialogArguments 得到父窗口传递的参数

?

window.showModalDialog(url,'',

? "dialogHeight: 550px; dialogWidth: 750px;center: yes; help: no;resizable: no; status: no;");

读书人网 >Web前端

热点推荐