17jul/113
How to download sexdumpert.nl photo’s or video’s with a simple Bash script
Here is the simple script which downloads all photos from sexdumpert.nl
Just save the file as run.sh in a directory and run it. It will save all photos found.
#!/bin/bash if [ ! -d 'files' ] then mkdir files fi for ((a = 0; a <= 999; a++)) do ca=`printf "%03d" $a` for ((b = 0; b <= 999; b++)) do cb=`printf "%03d" $b` for ((c = 0; c <= 999; c++)) do cc=`printf "%03d" $c` for ((d = 0; d <= 999; d++)) do cd=`printf "%03d" $d` url="http://mediadata.sexdumpert.nl/$ca/$cb/$cc/$cd.jpg" echo $url /usr/bin/curl $url -o "files/$ca-$cb-$cc-$cd.flv" done done done done
Here is the simple script which downloads all video's from sexdumpert.nl
Just save the file as run.sh in a directory and run it. It will save all video's found.
#!/bin/bash if [ ! -d 'files' ] then mkdir files fi for ((a = 0; a <= 999; a++)) do ca=`printf "%03d" $a` for ((b = 0; b <= 999; b++)) do cb=`printf "%03d" $b` for ((c = 0; c <= 999; c++)) do cc=`printf "%03d" $c` for ((d = 0; d <= 999; d++)) do cd=`printf "%03d" $d` url="http://mediadata.sexdumpert.nl/$ca/$cb/$cc/$cd.flv" echo $url /usr/bin/curl $url -o "files/$ca-$cb-$cc-$cd.flv" done done done done
Hope this for fills some people their needs
14jun/110
How to download a range of files with Curl and Bash
This is a really simple sniped how to download a range of files.
I found this very useful to download an image range of my old avatar script.
I lost my images but remembered an url where I uploaded them once. Happy me
1 2 3 4 5 6 7 | #!/usr/local/bin/bash # Range 1 to 75 for x in {1..75} do curl -O http://my.server.com/media/images_${x}.jpg done |
14jun/117
Download Redtube movies with a simple PHP class
For donations I build everything...
Simply put this file on a server where you want and start downloading
class RedTube { function form() { echo '<form method="post"><input type="text" name="url"><input type="submit"></form>'; } function download($url = null) { if ($this->validate($url)) { $content = $this->fetch($url); preg_match('#<h1 class="videoTitle">(.*)</h1>#', $content, $d1); //preg_match('#<source src=\'(.*)\' type=\\\"video/mp4\\\">#', $content, $d2); preg_match('#<source src=\'(.*)\' type=\'video/mp4\'>#', $content, $d2); if (!empty($d1[1]) && !empty($d2[1])) { header("Content-type: application/octet-stream"); header('Content-Disposition: attachment; filename="' . addslashes($d1[1] . '.mp4') . '"'); $this->fetch($d2[1], true); } } } private function validate($url = null) { if (preg_match('#^http://(www.)?redtube.com/[0-9]+$#', $url)) { return true; } return false; } private function fetch($url = null, $stream = false) { $handle = fopen($url, 'r'); $buffer = null; if ($handle) { if ($stream) { while (!feof($handle)) { echo fgets($handle, 4096); } } else { while (!feof($handle)) { $buffer .= fgets($handle, 4096); } } fclose($handle); } return $buffer; } } $rt = new RedTube; if (!empty($_POST['url'])) { $rt->download($_POST['url']); } else { $rt->form(); }




