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

78
Views
¿Puede dirigirse a un elemento en un iFrame desde el mismo sitio?

Lo que estoy tratando de hacer es abrir la URL del minicarro en un iframe en una página para poder obtener el total de la cesta del carrito. Pude hacer esto, pero cuando trato de apuntar a lo que está en el iframe, no puedo hacerlo. En el sitio, cuando consola.log "pre", veo que en la colección html, el HTML interno muestra lo que se genera. ¿Alguna idea de cómo o si podría apuntar a esto?

 var iframevar = document.getElementById('freeGiftiFrame'); var elmnt = iframevar.contentWindow.document.getElementsByTagName("pre"); console.log(elmnt)
 <iframe id="freeGiftiFrame" class="cartPopout" name="iframe_a" height="100px" width="100%"> <html> <head></head> <body> <pre style="word-wrap: break-word; white-space: pre-wrap;"> {"miniCartCount": 1, "miniCartPrice": "€&nbsp;30,00"} </pre> </body> </html> </iframe>

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Para cualquiera que tenga el problema de agregar = sandbox="allow-same-origin allow-scripts" es el truco para mí

about 4 years ago · Juan Pablo Isaza Report
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!