This one was very simple. It basically loops through, visits the pages, checks to see if there is a photo on the page and then saves the photo based on the category if it exists. Sometimes the robots are much more elaborate. It wasn't even worth writing a class because the code required wasn't more than could go in one method.
There are two photo examples down below the code are of au naturel vintage men, although they are no more offensive than the statue of david. Don't scroll if you don't want to see it.
<?
$dir = 'xpics/';
if(!is_dir($dir)){
mkdir($dir);
}
foreach(range(1, 30423) as $x){
//grab html
$html = file_get_contents('http://SOMEWEBSITE/postcontent/showfull.php?photo='.$x);
if(strstr($html, "Photo not found in the database!")){
echo "Pic ".$x.' not found';
continue;
}
//get photo name
preg_match("~http://SOMEWEBSITE/postcontent/data/(d+)/(.*?)"~", $html, $data);
$src = str_replace('"', '', $data[0]);
$category = $data[1];
$name = $data[2];
$category_dir = $dir.$category.'/';
if(!is_dir($category_dir)){
mkdir($category_dir);
}
$jpeg = file_get_contents($src);
file_put_contents($category_dir.$name, $jpeg);
echo "Saved pic #".$x;
}
?>

What is the story behind this one?

tinypliny: the site came pre-filtered, with only images of men.
The first bloke should totally consider donating his body to bodyworlds. Are those muscles for real?! He must work out half a day everyday.
Now look what you've done to me :/