Javascript to submit form of parent from within iframe


I have an iframe within a page with the page containing form field holders to hold data from the iframe (which is collected on submit of the form).
The iframe contains a dropdown and multilist

What I am looking for now is a way to get the parent form to submit when an onchange happens for the multilist...

Any ideas??
Who is Participating?
PlowmisterConnect With a Mentor Author Commented:
I have abandoned this approach...sticking with what I have ... thanks anyway
According that the iframe can access the outer page only if the are from the same domain you can simply do that:

document.getElementById('yourmultilist_id').onchange = function(e) {
    return false;

Put this code in your onload event.

Otherwise you can create a function:

function updateParentForm(e) {
    return false;

and assign it to the onchange event of your multilist.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.