ZenphotoCMS Forum
Position of arrows in the Zenpage Theme - Printable Version

+- ZenphotoCMS Forum (https://forum.zenphoto.org)
+-- Forum: Support (https://forum.zenphoto.org/forum-1.html)
+--- Forum: Themes (https://forum.zenphoto.org/forum-5.html)
+--- Thread: Position of arrows in the Zenpage Theme (/thread-7420.html)

Pages: 1 2


Position of arrows in the Zenpage Theme - sbillard - 2010-08-04

There is no way to get code automatically included in the theme other than the addPluginScript(). You could provide a function that emits the code, but the theme user would have to place a call to the function in his script in the appropriate place.

I am not sure why there is a difference in the behavior, though. The code above (as I read it) should [b]always[/b] load a new page, not a simply a new picture. That is what you get from the getNextImageURL() and getPrevImageURL() functions.

If you want to just load the image you would have to have Javascript that modified the Html




Position of arrows in the Zenpage Theme - acrylian - 2010-08-05

@huogas: No, no side effects, it's just a matter of how a theme is setup.

I agree if you don't want to load the page you have to write some js code for that. It is possible but can't hardly be generalize as it is HTML dependend (since you probably don't want only the image to change but the title, desc, arrows etc as well).




Position of arrows in the Zenpage Theme - Laurent - 2010-08-05

Thanks for your answer.
Here is the new code :

`

`
I'll try to do it with a function.

Laurent




Position of arrows in the Zenpage Theme - huogas - 2010-08-05

Laurent

What is the main difference with the previous code ?

Thanks

Gaston




Position of arrows in the Zenpage Theme - Laurent - 2010-08-06

When you're writing a comment for a photo, and if you made a spelling mistake, for example you use the left or right arrow to correct this. With the first code, the picture change ... not really good !
With the second code, you can use the keyboard arrow in a comment area.

Laurent




Position of arrows in the Zenpage Theme - huogas - 2010-08-06

Thanks Laurent.

It's just sad, you could have done a new game: try to catch the end of your comments before the picture changes... ;-)

Gaston




Position of arrows in the Zenpage Theme - Laurent - 2010-08-06

I made the plugin. You're right Sbillard is was simple ;-)
So you can see it in action on my site : http://www.latitudes-photos.com

You can download and have information at this page :
http://www.latitudes-photos.com/keyboardnav

But, my english is very poor so can someone can make a better translation please :-)

Thanks
Laurent




Position of arrows in the Zenpage Theme - huogas - 2010-08-06

Looks good. By the way, very very nice site and pictures.

Thanks Laurent

Gaston
ps: your english looks ok to me... ;-)




Position of arrows in the Zenpage Theme - acrylian - 2010-08-06

The English description is not that bad...;-). But maybe you should mention which keys you actually can use.

Will add an entry to our extensions section soon.




Position of arrows in the Zenpage Theme - Laurent - 2010-08-06

Thanks Acrylian.
I have update the description and a on witch version i have test it.

Laurent




Position of arrows in the Zenpage Theme - acrylian - 2010-08-07

Laurent, you might want to submit your site to the showcase.




Position of arrows in the Zenpage Theme - huogas - 2010-08-07

I second the proposal of Malte (maybe not for the same reasons).
Really a nice one.

Felicitations!

Gaston




Position of arrows in the Zenpage Theme - Laurent - 2010-08-07

@huogas:I apologize, i didn't see your answer before. Thanks a lot for the compliment.

@acrylian: Ok, for the showcase. Could you do it for me ?

Going to greece this evening, maybe i'll come back with good picture ... maybe.

Regards
Laurent




Position of arrows in the Zenpage Theme - acrylian - 2010-08-07

Laurent, sure, I have to do it anyway, normally we just don't add them without submission. I will add a screenshot of your site then. Have a nice trip.




Position of arrows in the Zenpage Theme - Laurent - 2010-08-08

Reply from Greece now.
Thanks a lot acrylian

Regards
Laurent




Position of arrows in the Zenpage Theme - huogas - 2010-08-08

In order to get the best of this function, I had to :
-use an anchor just over the image and
-modify slightly the plugin code to branch to the anchor (for not taking any "prime space" in the window):

window.location=nextURL+"#topimage
window.location=prevURL+"#topimage

Was there a more elegant way of getting that result ?

Thanks

Gaston