Ido Bukin
Ido Bukin

Reputation: 51

Jquery Iframe Popup

I want to open a link in a iframe popup when somebody click on a image, this is the code -

<div class="photo-container">
    <a href="<?php echo $offer_link1 ?>">
        <img src="./images/im12.png" height="100" width="100">
    </a>
</div>

How can i open the link in a iframe popup?

The URL is - http://beflirty.net/lp1/signup12.php

Thanks.

Upvotes: 1

Views: 11003

Answers (1)

nikhil
nikhil

Reputation: 895

try this

<script src="http://code.jquery.com/jquery-1.9.1.min.js" type="text/javascript"></script>
    <script>
 $(document).ready(function (e) {
 $("framediv").hide();
    $("#link1").click(
function (e) {

$("#framediv").css({'display':'block'});
});
 });

</script>


<div class="photo-container">
 <a name="link1" href="<?php echo $offer_link1 ?> " target="frame1">
     <img src="./images/im12.png" height="100" width="100">
 </a>
</div>

<div id="framediv">
 <iframe height="900px" width="1100px"  name="frame1" border="0px"></iframe>
</div>

Upvotes: 7

Related Questions