Using Scriptylightbox 3, is there some way to make the height in percent instead of pixels? On a desktop it’s not generally an issue, but with mobiles it can be. When the lightbox is viewed on smaller screens, the top and bottom can get hidden and the close button isn’t visible. If the height could be set at 80 or 90 percent of window, it would not get clipped off in certain circumstances. I guess. Please advise.
I forget (hopefully someone can remind me) but this is a setting on your page that is causing this, not the Action. The dimensions of the overlay ARE set to a percentage of the page height, not a pixel value per se. Do you have your site set to anything other than the application default for the Mobile page size? (Output tab of the Page Inspector.) Make a new site, without using a template, and see what the defaults are. Check that your page is set the same way.
Walter
On Oct 3, 2014, at 2:27 PM, cosjr email@hidden wrote:
Using Scriptylightbox 3, is there some way to make the height in percent instead of pixels? On a desktop it’s not generally an issue, but with mobiles it can be. When the lightbox is viewed on smaller screens, the top and bottom can get hidden and the close button isn’t visible. If the height could be set at 80 or 90 percent of window, it would not get clipped off in certain circumstances. I guess. Please advise.
Sorry it’s been a while getting back to this. Lot’s going on. Walter, comparing the site to a new template, they are identical in settings. As David said, height default is none. I’ve been carefully reconstructing much of the site because of other issues and have just noticed something interesting. When using Preview in Freeway, SL3 properly scales images to fit the 80% or so of window. (whether there are height/width entries or not). When using FW’s Preview in Browser, I get the same proper results. When the site is uploaded this is no longer the case. SL3 images are scaled full size whether they fit in the browser window or not. A perfect example, because the image is large, is the UPS icon on left. That image is on a master page used throughout the site. Shop and Design Signs Online - A Better Sign
The underlying issue here is that the image you are loading is very tall, and the aspect ratio of most screens is not that. This is further complicated by the fact that you have loaded the image into the overlay as a link to a page (so it goes into an iframe) rather than as a regular image. An image can be resized by CSS, but an iframe cannot (well, can, but not easily/predictably). Have you tried opening the lightbox with just the image in it?
In the process of looking at this, I also found another way to scale the overlay – viewport units – which is amazing and cool and does not require JavaScript to work, but also fails in IE < 9. Depending on your audience makeup, this may be a non-starter for you. I’ll see if I can find ten minutes to make a proof of concept for people to try.
Yes, very tall image which is why I chose it as the example. I am planning to work it differently. So ticking “Use Page/URL as Target” always results in an iframe! My novice approach was for the URL to link to an image thus allowing for future changes to the image without needing to modify the FW file. Will need to rework my approach. This clears matters up entirely for a lot of similar issues. I will see how your viewport units idea works.
Why then, does the sizing work while in FW Preview and FW Preview in Browser?