Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

56
Views
How to display iframe data outside in jquery

My iframe data loads only after 3-4 second due to some background process. Once its loaded in iframe, I want to display that data outside the iframe in main page.

iframe source page:

       <html>
       <body>
        <h2>This is a Iframe</h2>
        <input type="text" id="text2" value="Data">
       </body>
        </html>

main page:

  <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
  <body>
  <iframe src="iframecontent.html"  width="300" height="100"  name="ifm" id="ifm"></iframe>
  <input type="text" id="text1" >
  </body>
  <script>
 $(function(){
    $('#ifm').on('load', function(){
        var getdata = $('#ifm').contents().find('#text2').val();
        $('#text1').val(getdata);
     });
   });
  </script>
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!