Open GoogleCodeExporter opened 8 years ago
Never had to do this before but I would assume that you would have a button
outside the iframe like
<div class="button" id="dostuff" link="myeditor">DO stuff</div>
<textarea id="myeditor" class="rte"></textarea>
and some javascript something like
<script>
$("div#dostuff").click(function(){
var ed = $(this).attr("link");
$("#"+ed).iframe.exec_command(........);
});
</script>
basically you can access and modify the content of an iframe because it is off
the same domain so you can do alert(iframe.body.innerHTML) to look in an iframe
and
var el = parent.getElementById("dostuff");
el.innerHTML = "stuff done";
to modify the parent window from inside the iframe with javascript.
hope this helps
Original comment by spambot....@googlemail.com
on 3 Sep 2010 at 9:10
Original issue reported on code.google.com by
brett.th...@gmail.com
on 19 May 2009 at 9:49