PDA

View Full Version : I Can't get into the iframe?....any ideas?



tedteeter
11-24-2013, 03:11 AM
Greetings, Nov 23rd, 2013

Briefly, I popup a div from index and load a file into it with and iframe src, however afterwards while I can easily reference functions outside the iframe, div combination I cannot reference elements, divs content etc. within the iframes different php page? I have tried the reference to the frame id and then the div id within the different php in a dom combination such as the below, however all has failed! neither of the examples below worked?...any ideas?

Appreciatively,
Ted


document.mainiframe.document.getElementById('darray'+i).innerHTML='frame test data - '+i;
document.mainiframe[0].document.getElementById('darray'+i).innerHTML='frame test data - '+i;

molendijk
11-24-2013, 01:27 PM
Try:

frames.mainiframe.document.getElementById('darray'+i).innerHTML='frame test data - '+i;
The iframe must have name="mainiframe"