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

140
Views
How to reload principal page after close iframa

I need to reload my principal page after close iframe. I use jquery to open modal and .html() to add iframe html parameters.

This open when I do click on my id a href="#ex2"

<div><a href="#ex2" rel="modal:open" >Prueba de Maquillaje</a></div>

This call my funcion and add the iframe on my id idcart

<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
    <!-- jQuery Modal -->
    <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-modal/0.9.1/jquery.modal.min.js"></script>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/jquery-modal/0.9.1/jquery.modal.min.css" />
    <script>

                $('.close-modal ').click(function() {
                        location.reload();
                        });
                var requestOptions = {method:'GET', redirect:'follow'};
                fetch("https://modiface--locatelcolombia.myvtex.com/api/checkout/pub/orderForm/", requestOptions)
                .then(response => response.json())
                .then(function(r) {
                    cartId = r['orderFormId'];
                    $("#idCart").html("<iframe src='http://localhost:81/proyectoModiface/modiface/index.php?cartId="+cartId+"' class='frameModiface' id='pruebasId' allow='camera' name='iframe_a'></iframe>");
                    
                });
             
    </script>``` 

This is my idCart div id 

``` <div id="ex2" class="modal"><div id="idCart"></div></div>``` 
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!