get three random entries, but not any of the three latest
This is an open discussion with 3 replies, filed under Troubleshooting.
Search
If you want to keep this in a single DS then yes.
You could create one DS that pulls the latest third entry, using a Date field as the Output Parameter: order by Date, show one entry per page, and show page 3.
You can then create the DS that chooses random entries where the Date is “earlier than {$ds-latest-three}”.
Nice solution! Thanks.
I was going to suggest having 2 DS, one with 3 latest entries and another pulling 6 random entries. Then use XSLT to pick out of the 6 random entries, filtering out the possible 3 that may be the latest ones.
However, Nick’s suggestion is more elegant in that the logic is done on the data side rather than the template side.
Create an account or sign in to comment.
Well, the topic title says it all really: I want to create a DS where I randomly get three entries from a section, but I don’t want any of the three latest. Is it possible without going into the DS’ php-code?