Posted by Daniel Kirsch on 04/11/06 12:01
David Virgil Hobbs wrote:
> However using frames['iframeid'].document.body.innerHTML I am only able
> to change, in the contents of the iframe, the code in between and
> including the body tags; I am not able to change the code above the
> body tag such as what is in the head section and what is in the html
> tag.
Instead of using innerHTML you may create a new document and use
document.write()
You may also access the head element by using DOM methods like:
var htmlElm = document.documentElement;
var headElm = htmlElm.getElementsByTagName("head")[0];
But what are you trying to do in the head?
To change the title, you may use
document.title = "foo";
Daniel
Navigation:
[Reply to this message]
|