With HTML5, is there any way in IE11/Edge to populate a sandboxed iframe (<iframe sandbox></iframe>
) with HTML other than using a src
url? I am looking for a solution like srcdoc
which works with all other modern browsers.
Using src
with a data URI is not an option according to Microsoft as it "cannot be used [to] populate frame or iframe elements." Surprisingly, this does works for me in Edge but only for data URIs with less than 4096 characters.
All other options that I have found, e.g. in Alternatives to iframe srcdoc? and Html code as IFRAME source rather than a URL do not work for a sandboxed iframe.