RSS Feed for Specific Tags showing 20 newest photos
CWhitmer
Joined: 2010-01-21
Posts: 34 |
Posted: Sun, 2013-05-19 17:08 |
I use the mini slideshow for the main page on my website www.WhitmerDecks.com. <script> This works well and except that it shows the oldest photos that have the tag id of 4 associated with them. As I add more photos and tag them to be part of the slideshow on the main page they never show because the RSS feed starts showing from the oldest to the newest. What I would like is an RSS feed that will get the latest 20 photos that are tagged with a tag id of 4 instead of the oldest. Thanks for any help. |
|
Posts: 27300
I have never used the http://codex.galleryproject.org/Gallery3:Modules:rss_extra it might help.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 34
I looked into rss_extra, but it does not seem to have what I want either.
Actually, I could not get it to work at all.
Thanks for the response though.
Posts: 27300
I not good a DB queries. I think you would have to edit the tag_rss.php file.
$tag = ORM::factory("tag", $id);
to add a sort to that, but looking at the table it only has 3 columns and none are date or anything else sort-able.So I suspect a table join with the items_tags table would help but that is over my head.
Dave
_____________________________________________
Blog & G2 || floridave - Gallery Team
Posts: 34
The one thing I am good with is the database.
I can modify the DB query if I know where it is, but I don't know where the tag_rss.php file is.
It is not in any of the module folders on my server.
Does it actually reside on a remote server?
I can write the query to get he information I want.
Would look something like this.
SELECT
items.name,
items.created
FROM
items,
items_tags,
tags
WHERE
items.id = items_tags.item_id
AND items_tags.tag_id = tags.id
AND items.type = "photo"
AND tags.name = "WDHomeSS"
ORDER BY
items.created DESC
LIMIT 50
Posts: 27300
https://github.com/gallery/gallery3/blob/master/modules/tag/helpers/tag_rss.php#L33
Dave
____________________________________________
Blog & G2 || floridave - Gallery Team