Non-standard This feature is non-standard and is not on a standards track. Do not use it on production sites facing the Web: it will not work for every user. There may also be large incompatibilities between implementations and the behavior may change in the future.
Note that this also means the user won't be able to interact with the opener window until he closes the modal dialog. This feature is explicitly ignored by window. If the features parameter is a zero-length string, or contains only one or more of the behavior features chrome , dependent , dialog and modal the chrome features are assumed "OS' choice.
To pass extra parameters into the dialog, you can simply supply them after the windowFeatures parameter:. The extra parameters will then get packed into a property named arguments of type Array , and this property gets added to the newly opened dialog window.
Note that you can access this property from within anywhere in the dialog code. Another example. Since window. To be able to pass values back to the caller, you have to supply some object via the extra parameters. You can then access this object from within the dialog code and set properties on it, containing the values you want to return or preserve past the window.
If you set the properties of the retVals object in the dialog code as described below, you can now access them via the retVals array after the openDialog call returns. Get the latest and greatest from MDN delivered straight to your inbox. Sign in to enjoy the benefits of an MDN account. The compatibility table in this page is generated from structured data. Last modified: Feb 22, , by MDN contributors. Related Topics. If the name doesn't exist, then a new browsing context is opened in a new tab or a new window, and the specified resource is loaded into it.
Learn the best of web development Get the latest and greatest from MDN delivered straight to your inbox. The newsletter is offered in English only at the moment. Sign up now. Sign in with Github Sign in with Google. Chrome No support No. Edge No support No. Firefox No support No.
WebView Android No support No. Chrome Android No support No. Firefox Android No support No. Opera Android? Safari iOS? Samsung Internet Android No support No.