Questions tagged [showmodaldialog]

A deprecated way for creating and displaying a modal dialog box containing a specified HTML document.

From the MDN :

The Window.showModalDialog() creates and displays a modal dialog box containing a specified HTML document.

Deprecated

This feature has been removed from the Web standards. Though some browsers may still support it, it is in the process of being dropped. Do not use it in old or new projects. Pages or Web apps using it may break at any time.

144 questions
34
votes
4 answers

Why is window.showModalDialog deprecated? What to use instead?

I was developing a GreaseMonkey script which used window.showModalDialog. But before finishing it, I have discovered that Firefox 29 warns: Use of window.showModalDialog() is deprecated. Use window.open() instead. For more help …
Oriol
  • 274,082
  • 63
  • 437
  • 513
21
votes
1 answer

Return a value from window.open

We recently discovered that Chrome no longer supports window.showModalDialog which is problematic because our enterprise application uses this method. There is, apparently, a short term workaround that allows you to restore showModalDialog but it…
desautelsj
  • 3,587
  • 4
  • 37
  • 55
18
votes
2 answers

javascript - showModalDialog not returning value in Chrome

I made a small calendar popup in Javascript. Very simple, using the Calendar control from ASP.NET. I call the popup window with showModalDialog. In the modal window, changing the current month of the calendar causes problems because of the postback,…
ConnorsFan
  • 70,558
  • 13
  • 122
  • 146
17
votes
4 answers

Auto close modal dialog - After server code is done, close dialog in Google Spreadsheet

I have a Google Sheet that runs some Apps Script server code to connect to an SQL server. I want to show the message "loading..." in the modal dialog while data is being refreshed. I can get the modal to pop up, but I want to auto-close the dialog…
Nick Burke
  • 183
  • 1
  • 1
  • 7
10
votes
1 answer

ie11 issues with Nested showModalDialog

I am working on a Web Application that uses many modal dialogs to take inputs. The issue started when I started making the app compatible with IE11 (it works perfectly fine in IE8). The Modal Dialog boxes return values perfectly when when called…
8
votes
1 answer

window.opener.returnValue in Chrome with showModalDialog

I am trying to use window.opener.returnValue with showModalDialog. There are numerous references to a technique which can be used to workaround window.returnValue not working. However it just doesn’t seem to work in Version 23.0.1271.97 of…
Rob Sedgwick
  • 4,342
  • 6
  • 50
  • 87
7
votes
2 answers

How to close SP.UI.ModalDialog from button click in sharepoint?

I want to show Confirmation Dialog when user saves any document from EDITForm.aspx. So I have written following JavaScript code. function PreSaveAction() { var _html = document.createElement(); _html.innerHTML = "
mit
  • 1,763
  • 4
  • 16
  • 27
6
votes
1 answer

Javascript error when attempting to open a modal window in a modal window

The application is running on a windows server 2003 box using asp.net 2.0 and is an IE specific web app. There is a button that opens a form in an iframe using showModalDialog(...) from a function call located in the JavaScript. Here is an example…
The Sheek Geek
  • 4,126
  • 6
  • 38
  • 48
5
votes
1 answer

Height of newly opened dialog in Safari 8 is incorrect

first timer here! I am seeing some undesirable behavior when using Safari 8 in Mac OS Yosemite related to the height of dialogs created with the JS function window.showModalDialog(). Is this a browser bug or something else? I would like to be able…
5
votes
3 answers

Removal of the showModalDialog API

With the impending removal of the showModalDialog API from various browsers, our company like many others who provide large scale enterprise web applications are now faced with a significant dilemma. Whilst we have centralised the calls to…
Brett Postin
  • 11,215
  • 10
  • 60
  • 95
5
votes
3 answers

Display popup confirmation message with MVC C# after postback

Using MVC Framework with C# coding. The views are written in standard HTML code. I require a confirmation message saying "Your message has been sent" once the user clicks the submit button Here is the controller: public ActionResult…
Gman16
  • 183
  • 2
  • 6
  • 15
5
votes
1 answer

Why does window.showModalDialog throw an "Access is Denied" error?

I'm working on a legacy application that uses the IE-only window.showModalDialog command to display web pages in a modal dialog. Recently, I tried logging into the application as a different user and began seeing a dialog that says "Access is…
Vivian River
  • 31,198
  • 62
  • 198
  • 313
5
votes
1 answer

Modal dialog (showModalDialog()) is not functioning properly in IE9

Scenario : There is an input element in a HTML page where u can enter any numbers/text. If 2 consecutive characters are entered, then I am calling showModalDialog() method to open a pop up window which is having another input element. Whatever the…
4
votes
11 answers

Webdriver showModalDialog

We are using webdriver for our functional tests. But our application uses the showModalDialog JS function a lot to open a popup. When we try to test this functionality with webdriver it hangs from the moment the popup is opened. We tried several…
johan gee
  • 41
  • 1
  • 2
4
votes
1 answer

Determine if window was opened by window.showModalDialog?

Does anyone know how to figure out if a window was opened by window.showModalDialog()? window.opener returns the parent window when the new window is opened by window.open(), but for some reason when you use window.showModalDialog(), window.opener…
ryanulit
  • 4,983
  • 6
  • 42
  • 66
1
2 3
9 10