Announcement

  •  » Extensions
  •  » Disable Lightbox plugin for Mobile theme?

#1 2014-07-27 21:44:06

plumbum
Guest

Disable Lightbox plugin for Mobile theme?

Hello/Hi/Greetings,

Is there a way to disable Lightbox plugin for mobile theme, but keep it for desktop? Mobile theme does not work correctly if Lighbox is enabled.

Thank you

Piwigo 2.6.3
Operating system: Linux
PHP: 5.2.17 (Show info) [2014-07-27 12:41:36]
MySQL: 5.5.36-cll [2014-07-27 12:41:36]
Graphics Library: External ImageMagick 6.7.1-10

 

#2 2015-03-08 08:33:46

piwiman
Member
2014-11-24
6

Re: Disable Lightbox plugin for Mobile theme?

I also would be interested about this.

I first had the Lightbox plugin enabled but then I realized that then it is much more complicated to use the mobile to look at the photos. Without Lightbox you can look through the pictures by just sliding your finger and the picture is always full screen.

When you are using pc, it would be very nice that when you click the picture it would open up in full screen and changing the picture to the next would be easy (somehow). On a standard setup we are using a lot of screen to the tools and navigation. The Lightbox seems to solve this issue so it could be handy on pc (but not on mobile).

Or am I missing something? Is there a workaround?

Last edited by piwiman (2015-03-08 08:39:30)

Offline

 

#3 2015-03-16 09:54:45

piwiman
Member
2014-11-24
6

Re: Disable Lightbox plugin for Mobile theme?

Any help for this one?

Offline

 

#4 2015-10-28 23:57:38

Geoff
Guest

Re: Disable Lightbox plugin for Mobile theme?

That would be great! :)

 

#5 2015-10-29 08:06:17

piwiman
Member
2014-11-24
6

Re: Disable Lightbox plugin for Mobile theme?

Good that you agree. I find that for mobile phone Piwigo is working fine, but for pc I am missing a good way to show pictures. It would nice to be able to surf through the pictures so that they would fill the whole screen. Now you have only a small picture in the middle of the toolbars.

Offline

 

#6 2016-01-07 12:11:03

piwiman
Member
2014-11-24
6

Re: Disable Lightbox plugin for Mobile theme?

Please could the admin shortly comment if this is possible (referring to the title).

Offline

 

#7 2016-01-10 10:59:31

JACKY HUI
Guest

Re: Disable Lightbox plugin for Mobile theme?

Dear all,

I face the same problem.

To fix the problem, I introduce some dirty code changes to the lightbox module.

Inside the lightbox module, there is a main.inc.php file which controls the loading of the plugin.

I modified the function lightbox_plugin(..) and enable the lightbox scripts only when the system is not using mobile theme.

original script:
function lightbox_plugin($tpl_thumbnails_var, $pictures)
{
  include(LIGHTBOX_PATH . 'lightbox.php');
  return $tpl_thumbnails_var;
}

modified script:
function lightbox_plugin($tpl_thumbnails_var, $pictures)
{
  if (!pwg_get_session_var('mobile_theme')) {
        include(LIGHTBOX_PATH . 'lightbox.php');
  }
  return $tpl_thumbnails_var;
}


It works for me but it is dirty.

Jacky Hui

 

#8 2016-01-12 07:25:45

piwiman
Member
2014-11-24
6

Re: Disable Lightbox plugin for Mobile theme?

Thank you for this. I will have a try with that code change.

Offline

 
  •  » Extensions
  •  » Disable Lightbox plugin for Mobile theme?

Board footer

Powered by FluxBB

github twitter facebook google+ newsletter Donate Piwigo.org © 2002-2019 · Contact