showModalDialog and showModelessDialog?
ShowModalDialog: after being opened, the input focus is always maintained. You cannot switch to the main window unless the dialog box is closed. Similar to the running effect of alert.
ShowModelessDialog: after opening, you can randomly switch the input focus. It has no effect on the main window (it can be blocked at most. : P)
2. How can I leave a new window in the
Avoid the Cause Analysis of the new form displayed in showModalDialog. Generally, you need to use window. open. showModalDialog and showModelessDialog to return the value.
1. What are the differences between showModalDialog and showModelessDialog?
ShowModalDialog: after being opened, the input focus is always maintain
This article mainly introduces the js window. showModalDialog and window. the example analyzes window. showModalDialog and window. the definition, function, and usage skills of the open method. if you need it, refer to the example in this article to describe the js window. showModalDialog and window. open usage. Share it with you for your reference. The specific
The usage of window. showModalDialog () in JavaScript is described in detail.
Today, the pop-up subwindow is used in the project, and we think of two methods implemented using JavaScript. One is window. open (); one is window. showModalDialog () method. The latter is a pop-up window with a parent-child relationship. Th
When I use the showmodaldialog () function of JavaScript to display An ASPX page, there is a cache problem. The first time I showmodaldialog saw normal content, the content of the page that is viewed for the second time is the content of the first time. That is to say, the page is obtained directly from the cache, rather than from the server.
Program This page i
javascript| Function | cache | problem | show | page
When you use the JavaScript ShowModalDialog () function to display an ASPX page, there is a problem with caching, the first time you see the ShowModalDialog is normal content, and the second start to see the content of the page is the first time to see the content, T
function | cache | problem | show | page with JavaScript showmodaldialog () function to display an ASPX page, there is a problem with caching, the first time showmodaldialog to see the normal content, And the second start to see the content of the page is the first time to see the content, that is, the page is directly from the cache, rather than to the server to
Code that uses Div to simulate the showModalDialog mode menu effect today studies how to use javascript and p to create the display mode form of the current form, and a small example that makes the subform unable to operate!
I can refer to some of my online results for this effect. It is complicated because it integrates some other functions, here I will briefly summarize the principle of this effect:
Step
Code that uses Div to simulate the showModalDialog mode menu effect today studies how to use javascript and p to create the display mode form of the current form, and a small example that makes the subform unable to operate!
I can refer to some of my online results for this effect. it is complicated because it integrates some other functions, here I will briefly summarize the principle of this effect:
Step
change. Oh. Brother Tao means that you can pass in a parameter parameter when it is 1 ("Agentcode") when it is ShowModalDialog () and execute getElementById when it is 2 ("getElementById"). AgentName ") But this has a major problem, showmodaldialog () can only pass in three parameters surl,varguments,sfeatures > I said we could put the parameters in varguments, there's more harmony. Longge
ShowModalDialog is a jswindow object method, which opens a new page like window. open. The difference is: after showModalDialog opens the sub-window, the parent window cannot get the focus (that is, the operation cannot be performed)
1. What is ModalDialog?ShowModalDialog is a jswindow object method, which opens a new page like window. open.
The difference is: af
Window. Open is usually used to open a new window.
To obtain the control of the parent window, you can use window. opener to obtain the parent window.
However, if showmodaldialog is used, it is invalid.
If necessary, you need to modify the enabled syntax and the syntax in showmodaldialog.
To enable the syntax for the 2nd parameters, see self. The example is as follows:
VaR rc = Window.
The showModalDialog () method provided by IE is a very useful Web application function. Although the General website application is not very common, once it involves enterprise application-level Web development, it is very useful. Now, let me use a simple and easy-to-understand example to illustrate:This application requires two web files:1. Parent window (that is, the page used to control the pop-up window)ShowModalDialog.html2. subwindow (the page t
When showModalDialog is used, the data displayed is the data before the last modification. This is because the cache is saved on the page by default, therefore, the displayed data is not the case after modification. If you want to display the latest data, you need to set it on the page to cancel the cache.
Add the following code to the Head label of the showModalDialog page:
In this way, the page will
(Opacity = 50)$ ("Body"). addClass ("body1 ");ShowDetailsDialog (url, "600px", "400px", "yes ");$ ("Body"). removeClass ("body1 ");} In addition, there is a style sheet DefinitionCopy codeThe Code is as follows:. Body1{Background-color: #999999;Filter: Alpha (Opacity = 40 );} 6. How to pass a value between pagesShowModalDialog value transfer and refresh(1) showModalDialog example: the parent window transfers a value to the Child window, the Child Win
Usually open a new window using a window.open method.
To get the control of the parent window, you can use Window.opener to get the parent window
However, if you use ShowModalDialog ... is not valid
If necessary, you need to modify the open syntax and the syntax in ShowModalDialog
Open syntax The 2nd argument please go to self, example below
var rc=window.showmodaldialog (strurl,self,sfeatures);
And then th
Functions of the showmodaldialog function:Open a Child Window and pass data with the parent window. The biggest difference between it and window. Open is that after showmodaldialog opens the child window, the parent window cannot be operated.Usage:Vreturnvalue = Window. showmodaldialog (Surl [, varguments] [, sfeatures])Parameter description:SurlRequired paramete
Google Chrome does not support the showModalDialog modal dialog box and cannot return the returnValue. Many of you may have encountered this problem. The solution is very simple. the following ideas, you can see that Chrome version 37.0.2062.103 m does not support showModalDialog modal dialog box and cannot return returnValue.
Projects used previously cannot be executed normally.
I found a compromise an
is visible
Outerheight | Pixel value | Set the pixel height of a window (including a decorative border)
Outerwidth | Pixel value | Set the pixel width of a window (including a decorative border)
resizable | yes/no | Whether the window size can be adjusted
ScreenX | Pixel value | The pixel length of the window from the left edge of the screen
ScreenY | Pixel value | The pixel length of the window from the edge of the screen
ScrollBars | yes/no | Whether a window can have a scroll bar
TitleBar |
The return value of showModalDialog can be obtained in IE and Firefox, but Null is returned in Google Chrome. There is a good solution below, if you are interested, you can refer to the returned values of showModalDialog to obtain the returned values under IE and Firefox. However, Null is returned in Google's browser. The solution is described below.
Parent page:
The Code is as follows:
Function openwin
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.