How to display "today popular photos" in homepage?

bigu_c
bigu_c's picture

Joined: 2007-10-28
Posts: 421
Posted: Fri, 2013-10-25 13:43

As my title ask, anyone know how?

I tried search in this forum, and modules page but don't find out solution.

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Fri, 2013-10-25 19:37

I guess you need to explain by "today" do you mean in the last 24 hours?
So a query to see the items that have been viewed in the last 24 hours and sort them by views? Only displaying them? What if there is no views of any items in the last 24 hours? Is this a slideshow or a carousel or what? Where is it to be displayed, on a external page or the root album of Gallery?

A better user story is needed.

Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team

 
bigu_c
bigu_c's picture

Joined: 2007-10-28
Posts: 421
Posted: Sat, 2013-10-26 02:48

I guess you need to explain by "today" do you mean in the last 24 hours? --> Yes.
So a query to see the items that have been viewed in the last 24 hours and sort them by views? --> Yes.
Only displaying them? What if there is no views of any items in the last 24 hours? -> If not, will display latest update, or random photos.
Is this a slideshow or a carousel or what? --> This will display in "normal" like" albums, or photos I added on my site :)
Where is it to be displayed, on a external page or the root album of Gallery? --> I want to display on homepage (root album).

Thanks.

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Sat, 2013-10-26 02:58
Quote:
I want to display on homepage (root album).

Where on the the root album?

Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Sat, 2013-10-26 03:01
bigu_c wrote:
This will display in "normal" like" albums, or photos I added on my site :)

you need to expalin this a bit more as well.

Dave

_____________________________________________
Blog & G2 || floridave - Gallery Team

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Sat, 2013-10-26 03:01

a couple of different image block options based on RSS feeds. http://galleryproject.org/node/106581
But you'd need to create the feed.

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
bigu_c
bigu_c's picture

Joined: 2007-10-28
Posts: 421
Posted: Sat, 2013-10-26 03:07

Where on the the root album? -> Sorry, I understand wrong about "root album". I just want to display on homepage.

you need to expalin this a bit more as well. --> For example: In my homepage: domain.com, I choose "Add" -> "Addd photos" or "Add an album", after adding, my photos or my album will display in my homepage, then I want popular photos last 24 hours will display same like this.

(Sorry for my English).

 
tempg

Joined: 2005-12-17
Posts: 1857
Posted: Sat, 2013-10-26 12:28

(1) As far as I know, the Gallery database doesn't retain information about the last time an image was viewed. That being the case, I'm not sure that this is doable unless you add a field to the database and edit Gallery to update it each time an image is viewed.

(2) If you just want to find the photos that were viewed in the last 24 hours and sort by lifetime views, you can do it after you solve #1. If you only want to count views that also happened in the last 24 hours, that'll take more effort, more coding, and more tables/fields. (Gallery, by default, doesn't know WHEN the image was viewed; it only knows THAT the image was viewed.)