Image max-width with Lightbox plugin

Get help with installation and running phpwcms here. Please do not post bug reports or feature requests here.
Post Reply
trixs
Posts: 6
Joined: Fri 17. Jul 2015, 11:36

Image max-width with Lightbox plugin

Post by trixs » Tue 21. Jul 2015, 08:44

Dear All,
I have a question about best way for adapting image width in lighbox plugin.
Shortly, I have a single version of website for mobile and desktop devices. It's use kind of adaptive design with using meta name viewport for better fonts presentation.

Code: Select all

<meta name="viewport" content="initial-scale=0.75, width=device-width">
So if I use lightbox plugin with image preview width with the well suitable for desktop configuration like

Code: Select all

$phpwcms['img_prev_width']    = 538; //max width of the large preview image

or more I got image out of screen on both sides on my smartphone. What the best way to adaptive image width in ligthbox plugin for mobile devices with narrow screens with phpwcms?
For example for my smartphone I need to set

Code: Select all

$phpwcms['img_prev_width']    = 470; //max width of the large preview image
for image being in screen

I understand that it's not very good solution, because of image downscale and loading time.

User avatar
update
Moderator
Posts: 6359
Joined: Mon 10. Jan 2005, 17:29
Location: germany / outdoor

Re: Image max-width with Lightbox plugin

Post by update » Tue 21. Jul 2015, 10:47

It's mostly all about webdesign, logo design, new and old pages refresh, print BUT slowly switching to be supporter for the band Mykket Morton. Visit Mykket Morton on FB. Listen Mykket Morton and live videos on youtube.

trixs
Posts: 6
Joined: Fri 17. Jul 2015, 11:36

Re: Image max-width with Lightbox plugin

Post by trixs » Tue 21. Jul 2015, 13:08

No I didn't, thank you, I will check

User avatar
Oliver Georgi
Site Admin
Posts: 9436
Joined: Fri 3. Oct 2003, 22:22
Location: Dessau
Contact:

Re: Image max-width with Lightbox plugin

Post by Oliver Georgi » Wed 22. Jul 2015, 06:56

FancyBox is responsive
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Kleintierpraxis am Georgengarten

Post Reply