Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6082451
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T11:17:26+00:00 2026-05-23T11:17:26+00:00

A key screen in my application involves a HTML page with several iframe s

  • 0

A key screen in my application involves a HTML page with several iframes performing various functions. All of these will need access to jQuery. In the interest of speeding up loading time, and reducing HTTP traffic (though I know caching could help with this), it would be good if the jQuery code itself were loaded only once. If my page is like so

<html>
   <head>
      <script src="jquery-1.5.js" type="text/javascript"></script>
   </head>
      <body>
         <iframe src="other.html"></iframe>
         <div id="foo"> ... stuff here ... </div>
      </body>
</html>

Then inside other I can refer to parent.$('#foo') but that will refer to the parent’s “foo” element, not the child’s. Is there a way to use the parent’s “instance” of jQuery on the child document or elements in it?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T11:17:27+00:00Added an answer on May 23, 2026 at 11:17 am

    Have you tried:

    var $ = window.parent.$;
    $('#foo'); // parent's frame's #foo, is the same as "window.parent.$('#foo');"
    

    and:

    var $ = window.parent.$;
    $('#foo', document); // this frame's #foo because the current document is given as context
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In my Flex application when click F11 key the page gets into full screen
I'm writing a Java application that will have an on-screen number pad available for
In some screen capture software when you press a key it's possible for the
I'm working with an on-screen keyboard that needs to send key strokes to a
My application redraws the screen every time the mouse moves. I have not at
I need write a console application like as hiren boot screen: alt text http://xahoithongtin.com.vn/Images/diembao/2006_10/Hiren2.jpg
We need to develop a dashboard application for a giant screen. What it is
I want to disable the F11 key in my Silverlight application because I don't
I'm testing a full-screen Flash application. My preference is to drive the process with
I'm implementing this application where i need to pause it when the back key

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.