Note that there are some explanatory texts on larger screens.

plurals
  1. POiOS 7/iPad Safari not responding to javascript confirm dialog event
    text
    copied!<p>Summary: When "OK" button is clicked on a javascript confirm dialog, it does not execute the code in its section.</p> <p>Steps to Reproduce:</p> <pre><code>window.location = 'myApp://openMyAppUrl' ; timeoutIpad = setTimeout( function(){ var timeoutFired = new Date(); var timeElapsed = timeoutFired.getTime() - start.getTime(); if( timeElapsed &lt; 3000){ if( confirm("You need app to continue.")){ if(timeElapsed &lt; 10000){ var x = 1+1; window.location="http://google.com/getMyApp"; } } } }, 200); //Timeout values of 200, 500, 1500 were attempted but same results </code></pre> <p>To reproduce:</p> <p>1) Use the above js code on a webpage. 2) Click the first "OK" and then click the "OK" that comes from the confirm dialog.</p> <p>Expected Results: A redirection to <a href="http://google.com/getMyApp" rel="nofollow">http://google.com/getMyApp</a> should happen in 10 seconds if the app does not exist.</p> <p>Actual Results: The sub routine for the true condition for the confirm() dialog does not get executed. The following is seen on xcode console:</p> <p>Nov 5 09:24:06 Tests-iPad MobileSafari[327] : <strong>* Assertion failure in -UIApplication runModal:, /SourceCache/UIKit/UIKit-2903.23/UIApplication.m:9465 Nov 5 09:24:06 Tests-iPad MobileSafari[327] : *</strong> WebKit discarded an uncaught exception in the webView:runJavaScriptConfirmPanelWithMessage:initiatedByFrame: delegate: The view passed in does not have a window.</p> <p>Version: <strong>7.0.0-7.0.3</strong> I saw reports that issue was fixed in 7.0.3 but I don't see it.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload