fancybox-2

fancybox2 / fancybox causes page to to jump to the top

不打扰是莪最后的温柔 提交于 2019-11-26 23:40:54
I have implemented fancybox2 on a dev site. When I engage the fancybox (click the link etc) the whole html shifts behind it - and goes to the top. I have it working fine in another demo, but when I drag the same code to this project it jumps to the top. Not only with the links to inline divs, but also for simple image gallery. Has anyone experienced this? Dave Kiss This can actually be done with a helper in Fancybox 2. $('.image').fancybox({ helpers: { overlay: { locked: false } } }); http://davekiss.com/prevent-fancybox-from-jumping-to-the-top-of-the-page/ Jordanj77 is correct but easiest

Can Fancybox be responsive only horizontally for tall content?

為{幸葍}努か 提交于 2019-11-26 23:12:41
I have a site with some very tall images. I'd like for these images to respond in a responsive way horizontally, but not vertically. If they conform to the height of the browser, they become too small to see properly. Is there a simple way to accomplish this that I'm missing? See an example below. Click on the second thumbnail "bswift", then a small grey square to launch Fancybox. http://www.eaaronrossdesign.com/index2.php Try combining the fitToView and maxWidth API options like : $('.thumbs_small').fancybox({ openEffect: 'elastic', closeEffect: 'elastic', prevEffect: 'fade', nextEffect:

fancy box work with iframes in beforeShow function?

空扰寡人 提交于 2019-11-26 20:59:40
Im trying to dynamically set some values of my Fancybox object based on information stored in tags inside of an iframe which fancy box is loading. the problem is, the only time i can seem to get the CORRECT values out of the content (iv tried virtually every callback combo possible) is on the afterShow method. this causes a jumpy transition of the width and height which are reset after it is shown. $('.fancybox').fancybox({ openEffect : 'elastic', closeEffect : 'elastic', autoSize:true, afterShow : function() { var fancy = this; var h = $('.fancybox-iframe').contents().find('html').height();

Fancybox (jQuery) - Passing information from parent to iframe and iframe back to parent

瘦欲@ 提交于 2019-11-26 14:34:33
问题 I am trying to open a fancybox iframe on my page. Pass over some basic information to the iframe. Then I want to make it so that the iframe talks back to it's parent. I am passing nameid-1 throughout statically, though I would really like to have this as variable such as: var nameid=$(this).attr('nameid') I just don't know how to execute this all correctly as I am new to Ajax/Javascript and struggling with the logic. Base.html JS: <script type='text/javascript'> //<![CDATA[ // Popup Function

How do I make fancybox href dynamic?

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-26 12:46:26
问题 I have the following fancybox code: $(\'.fancybox\').fancybox({ \'autoScale\' : false, \'href\' : $(\'.fancybox\').attr(\'id\'), \'type\':\'iframe\', \'padding\' : 0, \'closeClick\' : false, //some other callbacks etc the problem is I have twenty different A tag id\'s on the page and I want the fancybox href attribute to take the id of the clicked element, ie the one that triggered the event. I have tried several things, none of them have worked! \'href\' : $(this).attr(\'id\'), \'href\' : $

fancybox2 / fancybox causes page to to jump to the top

☆樱花仙子☆ 提交于 2019-11-26 08:46:07
问题 I have implemented fancybox2 on a dev site. When I engage the fancybox (click the link etc) the whole html shifts behind it - and goes to the top. I have it working fine in another demo, but when I drag the same code to this project it jumps to the top. Not only with the links to inline divs, but also for simple image gallery. Has anyone experienced this? 回答1: This can actually be done with a helper in Fancybox 2. $('.image').fancybox({ helpers: { overlay: { locked: false } } }); http:/

Fancybox stuck loading iframe in IE

半腔热情 提交于 2019-11-26 08:32:31
问题 I\'m having problems loading a PDF in an iframe in IE using fancybox. When I click the link, I get the gif loader and it just spins forever. No errors in the console or on the page or anything like that. Problem occurs in all versions of IE. All other browsers work fine. Also, the PDF is an internal file. Here\'s some of the code: HTML <!DOCTYPE html> <html lang=\"en\"> <head> <meta charset=\"utf-8\"> <link rel=\"stylesheet\" type=\"text/css\" href=<?php echo base_url(\"templates/style1/css

fancy box work with iframes in beforeShow function?

不想你离开。 提交于 2019-11-26 07:46:55
问题 Im trying to dynamically set some values of my Fancybox object based on information stored in tags inside of an iframe which fancy box is loading. the problem is, the only time i can seem to get the CORRECT values out of the content (iv tried virtually every callback combo possible) is on the afterShow method. this causes a jumpy transition of the width and height which are reset after it is shown. $(\'.fancybox\').fancybox({ openEffect : \'elastic\', closeEffect : \'elastic\', autoSize:true,