Skip to content

Instantly share code, notes, and snippets.

@starenka
Created March 15, 2011 09:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save starenka/870509 to your computer and use it in GitHub Desktop.
Save starenka/870509 to your computer and use it in GitHub Desktop.
get links to Respekt PDFs
/*
Extracts links to all available PDFs in Respekt's archive
1) copy the javascript:$... line below
2) go to http://service.ihned.cz/respekt/respekt-v-pdf.php and log yourself in
3) paste the copied line into address bar and hit Enter
4) profit
this is just a js version of this gist https://gist.github.com/750404
*/
javascript:$('#main').prepend('<div id="dllinks" style="border: 1px solid black; width: 80%; height: 80%; z-index: 100000; position:absolute; overflow:auto; background-color:white"></div>');var start=0;$.each(ayn.slice(0,ayn.length-1),function(y,max){$.each(ah.slice(start,start+max),function(i,hash){console.log(year);var l='http://81.95.101.5/download/pdf_respekt/'+ay[y]+'/Respekt_PDF_'+ay[y]+'_'+an[start+i]+hash+'.pdf';$('#dllinks').append('<a href="'+l+'">'+l+'</a><br/>')});start+=parseInt(max)});;void(0);
/*
// non-minified version
$('#main').prepend('<div id="dllinks" style="border: 1px solid black; width: 80%; height: 80%; z-index: 100000; position:absolute; overflow:auto; background-color:white"></div>');
var start = 0;
$.each(ayn.slice(0,ayn.length-1),function(y,max){
$.each(ah.slice(start,start+max),function(i,hash){
var l = 'http://81.95.101.5/download/pdf_respekt/'+ay[y]+'/Respekt_PDF_'+ay[y]+'_'+an[start+i]+hash+'.pdf';
$('#dllinks').append('<a href="'+l+'">'+l+'</a><br/>');
});
start += parseInt(max);
});
*/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment