Skip to content

Instantly share code, notes, and snippets.

@dbuscombe-usgs
Created July 26, 2013 01:57
Show Gist options
  • Save dbuscombe-usgs/6085449 to your computer and use it in GitHub Desktop.
Save dbuscombe-usgs/6085449 to your computer and use it in GitHub Desktop.
Download pictures from a photobucket album
s = urlread('http://s1270.photobucket.com/albums/SERVERNAME/YOURUSERNAME/YOURALBUMNAME/?start=all');
indices = regexp(s,'pbthumburl=');
for k=1:length(indices)
tmp=strtrim(s(indices(k):indices(k)+100));
tmp=tmp(regexp(tmp,'"','once')+1:end);
tmp=tmp(1:regexp(tmp,'"','once')-1);
system(['wget ',tmp(1:regexp(tmp,'th_')-1),tmp(regexp(tmp,'th_')+3:end)]);
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment