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
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
Any help for this one?
Offline
That would be great! :)
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
Please could the admin shortly comment if this is possible (referring to the title).
Offline
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
Thank you for this. I will have a try with that code change.
Offline