title: getting about:blank in shouldStartLoadWithRequest while passing the data from javascript to objective-c using IFRAME in IOS 10
body: <p>I am passing my data from javascript to objective-c. for that I am using IFRAME.<br>
  Here is my code:<br>
  <strong>context.html</strong>  </p>
  
  <pre><code>function openCustomURLinIFrame(src)
  {
      alert(src);
      var rootElm = document.documentElement;
      var newFrameElm = document.createElement("IFRAME");
      newFrameElm.setAttribute("src",src);
      document.documentElement.appendChild(newFrameElm);
      //remove the frame now
      newFrameElm.parentNode.removeChild(newFrameElm);
      newFrameElm = null;
  }  
  </code></pre>
  
  <p><strong>Indoor.m</strong>  </p>
  
  <pre><code>- (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType
  {
      NSLog(@"Loading: %@", [request URL]);
      NSURL *url = [request URL];
      NSString *urlStr = url.absoluteString;
  
      return [self processURL:urlStr];
  
  }  
  </code></pre>
  
  <p>I am getting </p>
  
  <blockquote>
    <p>Loading: about:blank    </p>
  </blockquote>
  
  <p>I am using xCode 8.2.1 it is working well in IOS 9.3  but not working in iOS 10.2.</p>
  
  <p><strong>Edit:</strong><br>
  My alert screenshot in .html file.<br>
  <a href="https://i.stack.imgur.com/ExgF8.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ExgF8.png" alt="My alert screenshot in .html file"></a></p>
  
  <p><strong>Edit:</strong><br>
  Method in html file in which I call <code>openCustomURLinIFrame</code> method.  </p>
  
  <pre><code>function calliOSFunction(functionName, args, successCallback, errorCallback)
  {
      var url = "js2ios://";
      var callInfo = {};
      callInfo.functionname = functionName;
      //alert("Custom menu clicked !!"+functionName);
      if (successCallback)
      {
          //alert("Success !!"+functionName);
          callInfo.success = successCallback;
      }
      if (errorCallback)
      {
          //alert("Error !!"+functionName);
          callInfo.error = errorCallback;
      }
      if (args)
      {
          //alert("args !!"+args);
          callInfo.args = args;
      } 
      url += JSON.stringify(callInfo)   
      openCustomURLinIFrame(url);
  }
  </code></pre>
  
  <p>Help me to resolve this issue.</p>