iframe not loading correctly in IE 8
<p>I am creating an iframe with jquery by giving it a src but it is not working in IE8. </p>

<pre><code>$("#DB_window").append("&lt;iframe frameborder='0' hspace='0' style='width:100%;height:100%;' src='"+urlNoQuery[0]+"' id='DB_iframeContent' name='DB_iframeContent"+Math.round(Math.random()*1000)+"' onload='db_showIframe()'&gt; &lt;/iframe&gt;");
</code></pre>

<p>It makes a request but request is aborted so I changed it and tried accessing it with ajax</p>

<pre><code>$("#DB_window").append("&lt;iframe frameborder='0' hspace='0' style='width:100%;height:100%;' data-src='"+urlNoQuery[0]+"' id='DB_iframeContent' name='DB_iframeContent"+Math.round(Math.random()*1000)+"' onload='db_showIframe()'&gt; &lt;/iframe&gt;");
</code></pre>

<p>And make an ajax call to get the content</p>

<pre><code>var iframe = $("#DB_window").children('iframe');
        $.ajax({
            url: iframe.data("src"),
//            dataType : "text/html",
            success: function(content) {
                iframe.html(content);
            }
        });
</code></pre>

<p>But in the IE8 it only requests for the <code>"src"</code> url and doesn't requests for the css and js references in the page. So the iframe is not rendered properly, it comes only with data and thus have no styling with it. How can we request for iframe in IE.</p>