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

136
Views
El contenido HTML de un iframe no está presente después de cargar

Tengo una página web con un elemento iframe que apunta a un formulario externo (de un sitio web de terceros):

 <p><iframe id="ifmSearch" style="width: 100%; min-height: 800px;" title="Form" src="https://thirdpartysite.com"></iframe></p>

He escrito el siguiente código para leer el formulario de terceros incrustado en el iframe:

 $('#ifmSearch').on('load', function() { document.getElementById('myForm').addEventListener('submit', function(event) { event.preventDefault(); console.log(document.getElementById('notice').value); var form = new FormData(); form.append("email", document.getElementById('myEmail').value); var settings = { "url": "http://localhost/send-mail.php", "method": "POST", "timeout": 0, "processData": false, "mimeType": "multipart/form-data", "contentType": false, "data": form }; $.ajax(settings).done(function(response) { console.log(response); }).catch(error => console.log('error', error)); }); console.log('loaded'); });

Pero... el formulario con id myForm no está presente después de cargar el iframe.

Gracias de antemano por tu ayuda. Cualquier comentario o respuesta me será de ayuda.

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!