M
M
mrzgt2015-08-14 18:19:21
fancyBox
mrzgt, 2015-08-14 18:19:21

How to close fancybox window when clicking in its area?

There is a popup

// Покажем всплывающее окно
  if (!$.cookie('was')) {
$(document).ready(function() {
    setTimeout('$.fancybox.open({type: "image", href: "image/data/banner_skidka_seychas.jpg"})', 3000)
  
});
}

Now the window is closed when you click on the cross or click in the wrong area of ​​the window. How to make the window close and when you click on the banner itself that pops up in this window7

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry Ivanov, 2015-08-15
@DEMETRIUS666

try like this

$(' #id элемента ').click(function(){
        $.fancybox.close();
    });

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question