开发者

iFrame & Galleria Photo Gallery [makeshift multi album] -- resize? fullscreen? jquery? java?

开发者 https://www.devze.com 2023-04-05 12:19 出处:网络
So what I have now (http://itsdoom.com/tumblrstylewebsite.html) is the newest thing I have been working on.its very rough as of now.But what I am having trouble with is the image gallery.If you clic

So what I have now (http://itsdoom.com/tumblrstylewebsite.html)

is the newest thing I have been working on. its very rough as of now. But what I am having trouble with is the image gallery. If you click on 'work' it will scroll you down and you can see what I'm talking about. I wanted to have multiple albums so I placed the "Galleria" in an iFrame. with obvious problems. As I realize the way i have it setup now the Galleria / iframe is at 420px (h) x 820px (w), which looks good on the screen i'm working on now 1280x800, but if a user had a higher screen resolution, it would look too small, and with no ability to fullscreen the galleria, its a probl开发者_JS百科em.

so I have a couple questions..

  1. Is there anyway to make the Galleria fullscreen not only in the iframe but in the whole browser?

  2. Is there anyway to either resize the iframe // content (Galleria) to reflect a users screen resolution?

If there's a way to fullscreen that would be the best option because someone with a higher resolution screen would just be able to hit that. if not, hopefully the other option is possible.


Yes, you can (might work):

$(document).ready(function() {
  $('iframe[name="gallery"]').find('.galleria-fullscreen').bind('click', function() {
    $('iframe[name="gallery"]').css('position', 'absolute');
    $('iframe[name="gallery"]').width($(window).width());
    $('iframe[name="gallery"]').height($(window).height());
  });
});
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号