cyberalien — 2011-06-03T09:17:31-04:00 — #1
I have the following structure:
<input id="test-input" type="text" />
<iframe id="test-frame" src="whatever.php" />
.. more stuff ..
I need to change value of "test-input" from within that iframe. Typically I'd use
parent.document.getElementById('test-input').value = 'whatever';
but the problem is, iframe and document are on different domains, so I can't access parent.document
paul_wilkins — 2011-06-03T18:20:21-04:00 — #2
Can the child execute a parent function, that changes it instead?
cyberalien — 2011-06-03T18:33:37-04:00 — #3
Tested it, parent function can't be executed. Getting error "permission denied to access property 'testFunction'"
paul_wilkins — 2011-06-03T18:42:05-04:00 — #4
You may require a cross-domain communication solution then, one of which is easyXDM
cyberalien — 2011-06-03T18:44:58-04:00 — #5