Piwigo gallery – fil­ter pho­tos by a ra­ting score in the Batch Ma­nager

If you are using the Piwigo web gallery and wish to fil­ter out pho­tos by a ra­ting score to per­form some batch ope­ration on them, you mi­ght find that sli­ghtly challen­ging. Even if you’re using the plu­gin Batch Ma­nager Pre­fil­ters, you don’t have any ob­vi­ous way to fil­ter the pho­tos by a ra­ting in the Batch Ma­nager. I’ve found two ways to work around that.

1st way: search in the Batch Ma­nager

In the Batch Ma­nager, there’s a fil­ter na­med „Search“. You can use that to search for pho­tos with a cer­tain ra­ting score.

Se­lect the Search fil­ter and into the in­put field that ap­pears in­sert following: rating:3.96 (change the ra­ting va­lue, of course). Then click „Refresh photo set“ and pho­tos with the ra­ting spe­ci­fied should ap­pear.

You can also fil­ter out pho­tos with the ra­ting below/above a cer­tain va­lue. E.g. search query rating:<3 will fil­ter out pho­tos with the ra­ting lower than 3 (pro­ba­bly exclusive).

You can also in­sert rating:* to fil­ter out all pho­tos with any ra­ting and in­ver­sely rating: to fil­ter out pho­tos with no ra­ting.

Strange thing is the fil­ter by exact score doesn’t seem to always work but that mi­ght be my mi­s­take in the pro­cess so­mewhere.

2nd way: smart al­bums

Se­cond way is to cre­ate a smart al­bum with a help of the plu­gin Smart Al­bums which allows to cre­ate vir­tual al­bums with pho­tos that meet cer­tain cri­te­ria. One cri­te­rion avai­la­ble is ha­ving a ra­ting above/below a spe­ci­fied va­lue.

Af­ter you in­stall the plu­gin, a new item ap­pears in the Plu­gins section. In this settings page of the plu­gin, cre­ate a new al­bum, then click Edit, add a new fil­ter „Ra­ting score“ and in­sert de­si­red va­lues.

This will cre­ate a stan­dard vir­tual al­bum con­ta­i­ning pho­tos me­e­ting the cri­te­rion you’ve spe­ci­fied. You can re­ge­ne­rate the list of the pho­tos in the al­bum when the ra­ting of some pho­tos chan­ges or you add some new pho­tos into your gallery. You can also set au­to­ma­tic re­ge­ne­ration in the settings page of the plu­gin.

When you have the al­bum cre­a­ted and filled, you can nor­mally go to the Batch Ma­nager, fil­ter out the ra­ted pho­tos by the al­bum you’ve cre­a­ted and per­form stan­dard batch acti­ons on the pho­tos in the al­bum.

Leave a Reply

Your email address will not be published. Required fields are marked *