set innerHTML of an iframe

前端 未结 4 1794
死守一世寂寞
死守一世寂寞 2020-12-08 07:57

In javascript, how can I set the innerHTML of an iframe? I mean: how to set, not get.

window[\"ifrm_name\"].document.innerHTML= \"

Hi

\"
4条回答
  •  佛祖请我去吃肉
    2020-12-08 08:41

    In Firefox and Chrome (don't know about Opera), you can use the data: URI scheme.