How to bulk download files of one type from the WordPress Media Library?
February 9, 2013 2:56 PM   Subscribe

Is there a quick (or a quicker) way to download all files of a given type from the Media Library of a self-hosted WordPress site? The site in question has about 200 MP3s. I can easily sort out the MP3s by selecting "Audio." But how can I download them all at once? Is there a plug-in? FTP looks like a big pain, too, as these files are organized in folders by year and month, and there are several years here -- and many months with no uploads at all.
posted by houseofdanie to Computers & Internet (9 answers total)
 
HTTrack or another web crawler program can probably be rigged to only save URLs ending in ".mp3".
posted by XMLicious at 3:12 PM on February 9, 2013


Best answer: If your "uploads" folder isn't too ginormous, you could just download the entire directory, then run a local search on *.mp3 files and sort them that way.
posted by colorproof at 3:17 PM on February 9, 2013


Best answer: Are you comfortable with the command-line? You can use lftp in "mirror mode" to download entire directories, and use the --include option so it only looks for .mp3 files and not others.
posted by vasi at 3:40 PM on February 9, 2013


Best answer: I have used the firefox plugin DownloadThemAll! for similar tasks.
posted by phil at 3:47 PM on February 9, 2013 [1 favorite]


Response by poster: I guess I'm kind of an idiot. I have a MacBook Pro and haven't seen a command line for more than seconds at a time in many years. :P I just downloaded HTTrack, which seemed like a fantastic idea til my eyes got SUPER BIG at instructions like, "First, you'll need to install Apple Developer Tools," followed by all this... stuff... to type into a command line. I think it wants me to play some Missile Command.

Ooh, on preview, a new plug-in to look at!
posted by houseofdanie at 3:51 PM on February 9, 2013


Best answer: Wow, yeah, looking at those instructions for the Mac it does look horrendously complicated. Sorry about that, I've only used it on Windows and Linux where the installation is much more straightforward. Here's the Wikipedia category for free web crawlers if you want to try to find one that's more Mac-friendly.
posted by XMLicious at 4:18 PM on February 9, 2013


Best answer: Honestly download Filezilla or Cyber Duck and take 5 minutes to figure out the correct way to do this. It's not that hard. If you can use Finder you can FTP.
posted by humboldt32 at 5:08 PM on February 9, 2013


Response by poster: I was about to use my FTP client to take the whole uploads directory, then search for just the MP3s and put them in their own folder, a la colorproof's suggestion. Humboldt32 clued me in to the fact that I'm able to search files on the server. AHA. Thank you.

I'm not entirely sure why WP doesn't have a way to batch download anything, but you all made my evening much more pleasant.
posted by houseofdanie at 5:37 PM on February 9, 2013


Best answer: Ha! I feel like an idiot, because I forgot you can search via FTP as humboldt32 suggested. I use Panic Transmit and it works really well.
posted by colorproof at 6:06 PM on February 9, 2013


« Older What do you consider a healthy dynamic between...   |   Fiction help: Name something a math genius could... Newer »
This thread is closed to new comments.