Last image module for phoca gallery?

Phoca modules - support for all Phoca modules except Phoca Gallery modules
parasalo
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 15 Oct 2008, 09:39

Last image module for phoca gallery?

Post by parasalo »

Hi!

Congratulations for an excellent component. My question is about if there are a module for Phoca Gallery that sow the last uploaded image or the two latest images in a category.

Thank you!
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Last image module for phoca gallery?

Post by Jan »

Hi, there is only random image module yet, the last image module is planned...

but you can display last images at the bottom site of the category too, see:
https://www.phoca.cz/phocagallery/demo/i ... -box-image

statistics pane
If you find Phoca extensions useful, please support the project
parasalo
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 15 Oct 2008, 09:39

Re: Last image module for phoca gallery?

Post by parasalo »

Thank you Jan.

I know the statistics pane, and the random image module too, but I need a last image module to display the three latest images from a category in other sections of the web.

When do you thing the last image module will be finished to download?. I think that the php code could be similar of the random image module (something like, select * from "x category" order by id ASC 0,3 instead of random).

Thank you very much.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Last image module for phoca gallery?

Post by Jan »

yes, the php code will be similar... before doing this module, all Phoca Gallery modules and plugins should be rewritten to support features from version 2 (this takes a lot of time so I don't know when it will be done :( )

Jan
If you find Phoca extensions useful, please support the project
parasalo
Phoca Newbie
Phoca Newbie
Posts: 3
Joined: 15 Oct 2008, 09:39

Re: Last image module for phoca gallery?

Post by parasalo »

Hi Jan:

I've done some changes in the php code on mod_phocagallery_random_image.php at line 187. Simply, I've changed ORDER BY RAND() to ORDER BY idimage DESC and works fine to me.

Thank you very much.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Last image module for phoca gallery?

Post by Jan »

great to hear it, Jan :-( I will do this after I will update it to 2...

Jan
If you find Phoca extensions useful, please support the project
xLaM
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 18 Oct 2008, 04:35

Re: Last image module for phoca gallery?

Post by xLaM »

HI parasalo,
I have follow your step to change "ORDER BY RAND() to ORDER BY idimage DESC" but still can't, the image still show with random. :( can you help me? or mybe you can upload your working module.
xLaM
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 18 Oct 2008, 04:35

Re: Last image module for phoca gallery?

Post by xLaM »

Sorry for double post..
It's working for me now, i just delete "()" after RAND. But now i have one trouble again, how to display random module and last module with the same page?
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Last image module for phoca gallery?

Post by Jan »

then you should change the name of the files in zip file and of the classes, so these will be not the same modules ...
If you find Phoca extensions useful, please support the project
xLaM
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 18 Oct 2008, 04:35

Re: Last image module for phoca gallery?

Post by xLaM »

Jan wrote:then you should change the name of the files in zip file and of the classes, so these will be not the same modules ...
Thanks Jan, it's working for me now. I have two module on my website, phoca random image gallery & phoca last upload image :)

Phoca is the best image gallery:)
Post Reply