Accessing Html Document Content in other Frames
Posted by: Rick Strahls WebLog,
on 07 Jan 2009 |
View original | Bookmarked: 0 time(s)
Heres a question that I see pop up quite frequently on newsgroups: How do I access content across frames or an iFrame using JavaScript code? Its actually quite easy once you understand how the windowing mechanism in the browser works. Imagine you have two pages one that holds an iFrame and another that holds the content for the iFrame. Both the host page and the iFrame contain a <div id=message> tag that is used to write some content into the other frame. Heres the top level page: ...