I know that jQuery doesn't allow multi-domain access into iFrame's. I'm wondering if there is a workaround somehow?
I'm simply trying to set the text inside an input box to a pre-defined username from my DB.
I'm currently getting this error:
Uncaught SecurityError: Blocked a frame with origin "http://domain.com" from accessing a frame with origin "http://track.domain.com". Protocols, domains, and ports must match.
Which is expected as jQuery's documentation clearly states it's not possible using the .contents()
function: https://api.jquery.com/contents/
I'm simply curious if there is a workaround to this somehow?
$('#myframe').contents().find('#ext-comp-1001').val('username');
Here is the Fiddle: http://jsfiddle.net/jfreak53/8L2pJ/