in reply to download JPG series with error-handling

You might want to start checking for the existance of directories as well, depending on the max index you're trying. If the "42" dir doesn't exist, it doesn't make sense to try to get images 1.jpg through 1000.jpg from there either. Not sure if there is a server-independent way of checking this though.
  • Comment on Re: download JPG series with error-handling

Replies are listed 'Best First'.
Re^2: download JPG series with error-handling
by mhacker (Sexton) on Mar 29, 2005 at 11:56 UTC
    Forgot to mention that a very easy way to download URLs with numbers in them is with the "curl" utility.
    curl -O http://www.website.com/images[1-4]/pic[001-250].jpg
    will download images1/pic001.jpg, images1/pic002.jpg etc up to images4/pic250.jpg. Will also handle cookies etc for you if you want it to.