diff --git a/savefrom.net/savefrom b/savefrom.net/savefrom deleted file mode 100755 index 520afe8..0000000 --- a/savefrom.net/savefrom +++ /dev/null @@ -1,13 +0,0 @@ -#!/bin/bash -c="`tempfile`" -trap "rm $c" EXIT -ua='Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.12) Gecko/20101028 Firefox/3.6.12' -u="`urlencode <<< "$1"`" -curl -A "$ua" -c "$c" "http://savefrom.net/$1" -s > /dev/null -curl -s -A "$ua" -b "$c" 'http://en.savefrom.net/savefrom.php' -d "sf_url=$u&sf_submit.x=0&sf_submit.y=0" | tr -d \\n | -# Wasted half an hour on this crazy shit -sed -e 's/.*eval(unescape(\([^)]*\)).*/print(unescape(\1));/' | js | - sed -e 's/.*>\(var[^<]*\)<.*/\1/;s/\;var s=document.*tex/\;/;s/eval(\([^;]*\))\;.*$/\1\;'\''\;print(t);/' | js | - sed -e 's#window\['\''\\x65\\x76\\x61\\x6c'\''\](f)#print(f)#' | cat <(echo 'u62=function(a,b,c){return a.replace(c,b);};') - | js | - sed -e 's/eval/print/' | js | - perl -ne 's#.*?{"url":"([^"]*)".*#\1#g and print' | sed -e 's#\\\/#/#g' diff --git a/savefrom.net/savefrom-phantom b/savefrom.net/savefrom-phantom index ab2e547..3845553 100755 --- a/savefrom.net/savefrom-phantom +++ b/savefrom.net/savefrom-phantom @@ -9,7 +9,7 @@ page.open('http://savefrom.net/', function(status) { if (loaded == true) { //console.log(page.content); page.evaluate(function () { - var links = document.querySelectorAll('div[class="link_group"] > div[class="link"] > a[href*="://"]'); + var links = document.querySelectorAll('div[class="link-box"] > div > div[class="link"] > a[href*="://"]'); for (var i = 0; i < links.length; ++i) { var res = links[i].querySelector('span').childNodes.item(0).nodeValue.match(/\d+/); if (oldres > res) break;