[pwg.images.syncMetadata] accept image_ids as comma separated list #1890

Closed
opened 2026-10-05 01:00:15 +02:00 by adam · 2 comments
Owner

As described in #2169 :

When sending a request to Piwigo API, method pwg.images.syncMetadata, the list of image_ids is provided as an array. While this is certainly the "cleaner", here is what is sent: ws.php?format=json&method=pwg.images.syncMetadata&image_id[]=1&image_id[]=2&image_id[]=3

I think it would be more efficient to send image_id=1,2,3

... without breaking the way it currently works.

As described in #2169 : > When sending a request to Piwigo API, method pwg.images.syncMetadata, the list of image_ids is provided as an array. While this is certainly the "cleaner", here is what is sent: ws.php?format=json&method=pwg.images.syncMetadata&image_id[]=1&image_id[]=2&image_id[]=3 > > I think it would be more efficient to send image_id=1,2,3 ... without breaking the way it currently works. <!-- github-sync-id:2366684803 -->
adam closed this issue 2026-10-05 01:00:15 +02:00
Author
Owner

Once done, use this change in batch manager

Once done, use this change in batch manager <!-- github-comment-id:2182885505 -->
Author
Owner

warning : when checking the user input, I remember PHP regex cannot match repeating patterns beyond a few hundreds. You must explode the user input and check each token.

warning : when checking the user input, I remember PHP regex cannot match repeating patterns beyond a few hundreds. You must explode the user input and check each token. <!-- github-comment-id:2212431739 -->
Sign in to join this conversation.
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: adam/Piwigo#1890