Solution for js to process the acquisition of objects in the iframe subpage and parent page

Source: Internet
Author: User

[1] retrieve the dom object of the parent page from the Child page

Parent. window. $ ('# id '). val (""); [2] the parent page obtains the object of the Child page $ (window. frames ["iframeName" 2.16.doc ument ). find ('# subjectDg '). datagrid ('acceptchanges'); $ ('# iframeid '). contents (). find ('# id'); // ***** [3] The parent page calls the subpage method: reload () subpage js method written for yourself $ ('# parentIframeId') [0]. contentWindow. reload (); [4] The method of calling the parent page on the Child page loadTree () is the js method window of the parent page. parent. loadTree (); // refresh the tree menu parent on the left. loadTree ();

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.