Feature request: exclude albums from query
-
A nice feature of using WP_Query is that there is a convention to use negative values to exclude a certain id from a list. I use that kind of convention on my own plugins as well; it’s extremely useful.
Suppose that you wish to add all public Picasa albums except a few — like the “Recent changes”, “Blogger images”, and so forth, which Picasa tends to keep around and treat like actual albums. Instead of being forced to make those albums private (so that Shashin doesn’t “see” them) or to type all ids that you wish to include, it would make sense to have something like [shashin type=”album” id=”-5,-12,-43″] which would mean: “include all albums except the ones with id 5, 12, and 43″. I haven’t checked the code for Shashin, but if it goes through some of the WP API functions at some point, this should be ridiculously easy to implement. Of course, if it does direct SQL queries, it might be a little trickier to accomplish (and a bit less efficient since now one would need to add an additional query to delete the unwanted ids).
Note that this makes a lot of sense if you have hundreds of albums and just wish to exclude a handful.
- The topic ‘Feature request: exclude albums from query’ is closed to new replies.