Closed navyjax2 closed 8 years ago
IE has a native support for showModalDialog, so the polfill does not fire, and IE does not support generators, so the yield does not work.
This would have been extremely helpful information to post. I was attempting to use this to replace SP.UI.ModalDialog.showModalDialog() because of an issue where SharePoint was injecting "&IsDlg=1" at the end, and it was causing the form not to display - even if I put '?ID=0" at the end of the URL before it added this. I needed an alternate way to do a modal window. Fortunately I found jQuery 1.11.4's version of "dialog", but not before wasting a lot of time on this. Not a lot of code for alternate versions of modal windows has been made available for IE - this one could have been labeled as non-IE compliant in order to keep those that support IE apps from wasting their time.
Yeah! Just tried this in IE9 and Bang :s
Sorry, but supporting browsers which natively support showModalDialog
(i.e. IE) exceeds the goal of this polyfill.
From the live demo site, http://niutech.github.io/showModalDialog/demo.html, in IE 11, clicking on the button using Yield does nothing, and clicking the button using Eval has a pop-up window, not an inset modal window within the browser. This does not behave at all like SP.UI.ModalDialog.showModalDialog() I thought this was supposed to replace.