6. Implementation of window pop-up in different browsers
If ($. browser. MSIE ){
Window. showmodaldialog (Openurl, argumentobj, size + "scroll: No ;");
} Else {
VaR win = Window. Open (Openurl ,"",
Size + "scrollbars = No, dialog = Yes, modal = Yes, toolbar = No, menubar = No, resizable = No, location = No, status = No ");
Win. Focus ();
}
7. A subclass window is displayed. Pass the parameters of the subclass window to the parent class window (FF & IE)
If ($. browser. MSIE ){
Window_value = Window. dialogarguments. argumentobj. windowid;
Channel_value = Window. dialogarguments. argumentobj. channel;
} Else {
Window_value = Window. opener. windowid;
Channel_value = Window. opener. channel;
}
8. The super disgusting IE does not support CSS selector. Fortunately, jquery can do it in seconds.
$ ("Input"). Each (function (){
If ($ (this). ATTR ("type") = "checkbox" | $ (this). ATTR ("type") = "radio "){
$ (This). addclass ("MP ");
}
});
9. showmodaldialog Method
Creates a modal dialog box that displays the specified HTML document.
Syntax
Vreturnvalue
=
Object
. Showmodaldialog (
Surl
[
,
Varguments
]
[
,
Sfeatures
]
)
Parameters
| Surl |
Required. String That specifies the URL of the document to load and display. |
| Varguments |
Optional. Variant That specifies the arguments to use when displaying the document. Use This parameter to pass a value of any type, including an array Values. The dialog box can extract the values passed by the caller from The Dialogarguments Property of Window Object. |
| Sfeatures |
Optional. String That specifies the window ornaments for the dialog box, using one or more of the following semicolon-delimited values: dialogheight: sheight Sets the height of the dialog window (see remarks for default unit of measure). dialogleft: sxpos Sets the left position of the dialog window relative to the upper-left corner of the desktop. dialogtop: sypos Sets the top position of the dialog window relative to the upper-left corner of the desktop. dialogwidth: swidth Sets the width of the dialog window (see remarks for default unit of measure). Center: {Yes | no | 1 | 0 | on | off} Specifies whether to center the dialog window within the desktop. The default isYes . Dialoghide: {Yes | no | 1 | 0 | on | off} Specifies Whether the dialog window is hidden when printing or using print Preview. This feature is only available when a dialog box is opened From a trusted application. The default isNo . Edge: {sunken | raised} Specifies the edge style of the dialog window. The default isRaised . Resizable: {Yes | no | 1 | 0 | on | off} Specifies whether the dialog window has fixed dimensions. The default isNo . Scroll: {Yes | no | 1 | 0 | on | off} Specifies whether the dialog window displays scrollbars. The default isYes . Status: {Yes | no | 1 | 0 | on | off} Specifies whether the dialog window displays a status bar. The default isYes For untrusted dialog windows andNo For trusted dialog windows. unadorned: {Yes | no | 1 | 0 | on | off} Specifies Whether the dialog window displays the border window chrome. This Feature is only available when a dialog box is opened from a trusted Application. The default isNo . |