Invoking a function with jsonp
<p>I have some html5 postMessage code:</p>

<pre><code>    window.addEventListener("message", FA.recieveMessage, false);
</code></pre>

<p>That listener invokes this function:</p>

<pre><code>FA.recieveMessage = function(e){
if (e.data == "closeFA"){
            console.log("Type of data: "+e.data);
}
};
</code></pre>

<p>Now on ie8 this code doesnt work, cause it doesnt support html5 messaging. So I thought if there is a way to invoke that function by sending an ajax request of type jsonp!?</p>

<p>Is there a way to emulate messaging with jsonp?</p>

<p>if i do send jsonp request to another server, does it mean that it is a new request and it wont be aware of all the events that were triggered now?</p>

<p><strong>UPDATE</strong></p>

<p>Okay here is what I want. I want to close an iframe. So on one page, I have got this javascript:</p>

<pre><code>        $.ajax({url:      'http://api.apps.com/html/'+FA.appID,
      data:      {},
      dataType: 'jsonp',
      timeout:  10000,
      jsonp: "closeIFrame"
      });
</code></pre>

<p>This should instruct the apps/html page to invoke the closeIframe function is that right?</p>

<pre><code>function closeIFrame() {
    jQuery("#fa-iframe-container").fadeOut(300, function(){ jQuery(this).remove(); });
FA.bannerShown = false;
</code></pre>

<p>}    </p>
