When needing to download a whole folder with wget, I’ve always run into problems with the mirror option, which is what everybody points towards when somebody asks how to achieve this. It creates massive unnecessary directory structures, leaving actually what you want hidden somewhere within. I found a command today, which circumvents this nonsense, and just downloads the contents of the folder you point it at…
wget -nd -nH -r http://www.site.dir/name/goes/here
The -nd can also be entered as –no-directories in verbose form. This stops the command creating the folder hierarchy on your local machine.
The -nH (–no-host-directories) stops the command from creating a folder labelled with the domain name at the top of the hierarchy (in the example above – http://www.site.dir).
Works a charm!