I would like to know how to go about exporting a load of image ID's based off the image name. For example

'how to dig gold' search may have a load of images like

how to dig gold.mp4001.jpg
how to dig gold.mp4002.jpg
how to dig gold.mp4003.jpg
how to dig gold.mp4004.jpg
how to dig gold.mp4005.jpg

Their wordpress image IDs are along the range of 8322-8326. I would like to run a single command to do this if possible as I will be doing this for hundreds of different keywords. The results should look like the following

how to dig gold-8322
how to dig gold-8323
how to dig gold-8324
how to dig gold-8325
how to dig gold-8326
  • can you explain your problem lil bit more? this makes no sense to me
    – Vishwa
    May 22 '19 at 11:28
  • There are a load of images called how to dig gold.mp$$$$.jpg I need to run a command that searches for this keyword 'how to dig gold' and exports all the attachment IDs for images in our media that contain that exact search term.
    – Toodarday
    May 22 '19 at 11:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.