ZenphotoCMS Forum
Keyboard plugin not working - Printable Version

+- ZenphotoCMS Forum (https://forum.zenphoto.org)
+-- Forum: Support (https://forum.zenphoto.org/forum-1.html)
+--- Forum: Plugins (https://forum.zenphoto.org/forum-6.html)
+--- Thread: Keyboard plugin not working (/thread-10442.html)



Keyboard plugin not working - Ruriko - 26-09-2012

I am using the keyboard plugin here http://www.zenphoto.org/news/keyboard-plugin I installed and activated and I tried testing but it doesn't work. I can't use the left & right keyboard to navigate images.

Is there another plugin that can navigate images using the keyboard?




Keyboard plugin not working - acrylian - 26-09-2012

No, all known are listed there. I don't know that one but it might require adjustments depending on the theme.

You can try this jQuery javascript code on a normal theme's image.php:
`
$(function() {
$(document).keyup(function (event) {
if (event.keyCode == 37) {
// Links

            window.location.href="";

        } else if (event.keyCode == 39) {
            // Rechts

            window.location.href="";

        }
        });
    });

`




Keyboard plugin not working - Laurent - 26-09-2012

Oups !

Can you download it again and report here please. I made a few change.




Keyboard plugin not working - Ruriko - 27-09-2012

Thanks the plugin is now working




Keyboard plugin not working - pvankempen - 20-10-2012

The keyboard-plugin worked fine for me right away ... for images (i.e. in the image.php page). But I was surprised it didn't also handle left/right arrows in the album.php page (to navigate between albums). I got that working by making a minor change to the plugin:

if ($_zp_gallery_page = 'album.php') { var nextURL=""; var prevURL=""; } if ($_zp_gallery_page = 'image.php') { var nextURL=""; var prevURL=""; }




Keyboard plugin not working - Laurent - 20-10-2012

Yes, you're right.
i can include your change in the file if you are ok.




Keyboard plugin not working - pvankempen - 20-10-2012

Sure, feel free to include it.




Keyboard plugin not working - Laurent - 21-10-2012

Thank you,

Your change as been include in the file.