Take 2: Download script for springerlink.com Ebooks
NOTE: This script is apparently against the licensing contract between universities and Springer, see: http://www.bib.hm.edu/aktuelles/news/newsdetail_9984.de.html
NOTE 2: I do not maintain this script anymore. Please look for an alternative.
Seems like quite some people are interested in my bash script for downloading ebooks from http://springerlink.com.
That script has some quirks, the greatest of all that it was written in bash which makes it kind of hard to implement new features. And one which was requested was support for books which span multiple pages on SpringerLink.
So here I present springer_download.py
- a Python rewrite which should handle all the old links and some more. This is the very first program I’ve written in Python. And since it has to run on the Zedat servers it’s limited to Python 2.4.x without any fancy shmancy additions (a pity, since I’d love to use urlgrabber or pycurl).
the script
You can find the sources on GitHub: http://milianw.github.com/springer_download/
I plan to put all my future code snippets in public repositories on GitHub. That way you can easily track changes and stay up to date. GitHub also has a nice “download” feature which you can use to get the current version. You can find my profile and my repositories at http://github.com/milianw
Note: This script is intended to be run under Linux or other *nix’es which fulfill the requirements (Python 2.4.x, iconv and pdftk). Windows is not supported.
TODO
- introduce multithreading for faster / simultaneous downloads
- add speed to progressbar
- use progressbar in source-downloader
- use one git-repo per project (makes links work properly)
Comments
Want to comment? Send me an email!
Comment by Felix Krull (not verified) (2012-11-08 12:40:00)
Hi! IMHO ist das Skript nun nicht mehr einsatzfaehig. Die haben die Seiten und damit auch das Namensschema verändert. Es sollte anpassbar sein, aber ich kann es nicht.
Grüße Felix
Comment by Anonymous (not verified) (2012-11-12 08:42:00)
they pretty suck. damn, can someone help or does someone has got some tips how i can fix the code. i would appreciate verily, thx anyhow.
Comment by Anonymous (not verified) (2013-04-29 08:11:00)
it’s easy. Download firefox and take the download extension called Downthemall. Right click on the page ( in firefox ) click on downthemall and put the tick on filter of pdf docs and click on start. You will wonder how easy it was… :)
Comment by Anonymous (not verified) (2012-11-12 09:13:00)
Try out this fork: https://github.com/MalteSchledjewski/springer_download
Comment by Anonymous (not verified) (2012-11-12 15:27:00)
i am baffled and amazed. ingenious. thx mate, verily. well i can’t offer a spoon but maybe an impalpably and puny contribution to the table manners (don’t know if i am right resp. up2date with the possibly new cobweb): try not to come up to 75 files each 1/2 hour.
Comment by Anonymous (not verified) (2012-12-10 02:35:00)
There’s a remake of Milian Wolff’s great tool available from this website: <http://tovotu.de/dev/518-Neuer-SpringerLink- Downloader/>
Use google translate if you don’t understand the German description: http://translate.google.de/translate?sl=de&tl=en&u=http%3A%2F%2Ftovotu.d…
Seems to work great and preserves table of contents as well as page labeling for downloaded books.
Comment by Matze (not verified) (2012-10-22 23:10:00)
Since a few days/weeks the script merges the chapters not correctly! The chapters are in random order in the pdf. Anyone has an idea?
Comment by Matze (not verified) (2012-10-22 23:09:00)
Since a few days/weeks the script merges the chapters not correctly! The chapters are in random order in the pdf. Anyone has an idea?
Comment by Dennis (not verified) (2012-10-22 08:45:00)
Hi, the script always worked flawlessly until I tried to download a book yesterday. It’s not that it’s not running, it just forgets the last chapter (backmatter.pdf) and the coverpage. Best regards.
Comment by Paul (not verified) (2012-10-13 02:22:00)
Vielen, vielen Dank, Milian und ebenso der community, welche emsig nach Verbesserungen trachtet. Das ist eine große Erleichterung (-wie schön, wenn doch ALLE Lektüre online wäre; was die derzeitige Episteme wohl noch länger zu unterbinden weiß)
Bei manchem Buch bekomme ich allerdings derart Fehlermeldung angezeigt: “… found 500 chapters downloading chapter 1/500 httphttp:http:http:http:http:http:http:http:http://springerlink.com/content/pln81m2474hxmpn6/fulltext.pdf -8192000%
ERROR: downloaded chapter http://springerlink.com/content/pln81m2474hxmpn6/fulltext.pdf has invalid mime type text/html - are you allowed to download Wörterbuch der Psychotherapie? ” Weiß wer einen Rat?
Comment by Paul (not verified) (2012-10-13 04:18:00)
oder: “downloading chapter 72/201 http://springerlink.com/content/x5w42567v106m086/fulltext.pdf 100%
ERROR: downloaded chapter http://springerlink.com/content/x5w42567v106m086/fulltext.pdf has invalid mime type text/plain - are you allowed to download Psychopraxis?”
-Es scheint wohl auch nicht unbedingt an der Größe bzw. Anzahl der chapter zu liegen, wie ich anfänglich vermutete (-zumindest gelang eine Datei mit über 400 chapters)
Sofern es glückt, erscheinen dann nur noch manchmal Kapitel in falscher Reihenfolge; aber immerhin sind sie irgendwo im Dokument enthalten. Woran könnte das liegen?
Comment by Paul (not verified) (2012-10-13 02:20:00)
Vielen, vielen Dank, Milian und ebenso der community, welche emsig nach Verbesserungen trachtet. Das ist eine große Erleichterung (-wie schön, wenn doch ALLE Lektüre online wäre; was die derzeitige Episteme wohl noch länger zu unterbinden weiß)
Bei manchem Buch bekomme ich allerdings derart Fehlermeldung angezeigt: “… found 500 chapters downloading chapter 1/500 httphttp:http:http:http:http:http:http:http:http://springerlink.com/content/pln81m2474hxmpn6/fulltext.pdf -8192000%
ERROR: downloaded chapter http://springerlink.com/content/pln81m2474hxmpn6/fulltext.pdf has invalid mime type text/html - are you allowed to download Wörterbuch der Psychotherapie? ” Weiß wer einen Rat?
Comment by indianahorst (not verified) (2012-06-06 14:56:00)
Es scheint, dass das Script leider nicht mehr funktioniert… egal ob ich -l LINK oder -c ISBN verwende, ich erhalte immer folgende Fehlermeldung:
$ ./springer_download.py -c 978-3-8348-1937-6 File “./springer_download.py”, line 92 print “fetching book information…\n\t%s” % link ^ SyntaxError: invalid syntax
bzw:
$ ./springer_download.py -l “http://www.springerlink.com/content/978-3-8348-1937-6/#section=1062052&page=1” File “./springer_download.py”, line 92 print “fetching book information…\n\t%s” % link ^ SyntaxError: invalid syntax
Comment by Anonymous (not verified) (2012-08-14 12:36:00)
Vielleicht etwas sehr spät, aber benutzt du Arch Linux (oder andere Distri die ‘python’ standardmäßig mit Python 3 belegt)? Dann musst du das Skript explizit mit python2 aufrufen oder im Skript die erste Zeile anpassen: Ersetze python durch python2
Comment by Anonymous (not verified) (2012-07-09 18:24:00)
Das Skripts funktioniert nach wie vor einwandfrei. Aufruf ist z.b. $ ./springer_download.py -l http://www.springerlink.com/content/978-3-8348-1937-6/
Comment by Anonymous (not verified) (2012-03-10 13:48:00)
Goodmorning guys, I really wanted to download some books from springerlink and my library has the right for it. But as i saw here it is with phyton scripting and linux. Im am totally noob in scripting and im not fomilier with linux. I hope within a few days to have installed linux (UBUNTU) on my laptop. I have already been searched for needed software…. but i dont understand the” iconv” requirement… is this already availiable when you download php5?
I really can use some extra help. The best would be if someone give me steps to follow from installation phyton till downloading a book.
Hope to hear soon from you guys.
Kind regard,s Marius
Comment by ubuntifa (not verified) (2012-02-21 15:33:00)
Thank you for this great little piece of free software. Saved a lot of time!
Comment by Mideag (not verified) (2012-02-10 11:22:00)
Hi Milian thank you very much, this script has saved me several clicks, it has been very helpful :P
Comment by Enno (not verified) (2012-01-13 08:32:00)
Dear Milian, thank you for this nice script which is very useful for me. If I’m outside of the university network I have to use a proxy to get the necessary IP to access springerlink.com. Is there a way to use your script with a proxy? Best wishes, E.
Comment by liob (not verified) (2011-11-20 22:38:00)
Hi,
I have taken the liberty to write a script that allows you to download ebooks from the thieme ebook library as pdf. You can find it at http://github.com/liob/thieme2pdf
Comment by Tatome (not verified) (2011-11-18 13:49:00)
Great script, thanks. This saves a lot of fiddling with bash or clicking on download links on my part.
One thing, though: I monkey-patched the script so it doesn’t bail out if it can’t download a chapter. It would be a nice idea to have a switch for that; it could even insert pages into the merged document where chapters were left out.
Cheers, Johannes
Comment by Anonymous (not verified) (2011-11-01 13:01:00)
Hi,
after creating the bookTitle, around line 121, you should check the length of it to avoid max. filename length problems. See http://www.tutorialspoint.com/python/os_fstatvfs.htm how to get the max. filename length. Would be nice ;-) By the way, good job with this program.
Greetings, Mo
Comment by Anonymous (not verified) (2012-02-04 20:06:00)
I don’t know anything about python but yeah, that would be nice. Or does anyone have another solution when having filename length problems? After succesfully downloading the whole book, the script is unable to save the merged pdf-file (Grundkurs_Statistik_in_den_Sozialwissenschaften_- _Eine_leicht_verstaendliche,_anwendungsorientierte_Einfuehrung_in_das_sozialwissenschaftlich_notwendige_statistische_Wissen.pdf) because the file name ist too long.. any ideas?
Comment by Hans (not verified) (2011-09-07 16:53:00)
Hi, ich bekomme folgenden Fehler nach ein paar Kapiteln (er läd immer 3-5 Kapitel, dann bricht es ab):
Comment by Milian Wolff (2011-09-08 12:25:00)
Hm maybe a new protection from springerlink that does not allow to download many chapters in short time?
I don’t know… Try to add an
import time
to the other imports at the top of the downloader script. And then add before thereturn response
indef geturl(url, dst)
the following:time.sleep(1)
. Increase the sleep time if it does not work.bye
Comment by Anonymous (not verified) (2012-10-19 12:48:00)
indeed, it is, so shall i put it into the if-clause or the else-clause?? -because i put it in the else-clause and it worked astonishingly fine, ..so far.. but i rather like to slow it down now.. trust me.
btw, a qualified note: it is better to go not under ~25 sec each when saving some more of these in order to avoid the cobweb and getting unpleasant post. thanks to milian, thanks to the community, for sharing and caring, have a good life, with high regards and honesty, -a friend
Comment by Anonymous (not verified) (2012-10-19 13:21:00)
‘kay, sorry mate for toiling and spamming: it was the if-clause. but why did it solve my problem as well when i put it into the else clause?.. just mumbling..
Comment by Hans (not verified) (2011-09-12 17:30:00)
Thanx dude, it seems to work now. With time.sleep(1) it screened the same error. I increased the level to (10) and now i downloaded 2 books without any error warning.
hans
Comment by Volker (not verified) (2011-09-03 15:24:00)
Hallo, danke für das Skript. Generell funktioniert es sehr gut. Leider muss ich nach jedem Kapitel Benutzername und Passwort (VPN-Zugang) eingeben. Hat jemand das gleiche Problem? Kann man da Abhilfe schaffen?
Grüße Volker
Comment by James Bond (not verified) (2011-07-29 01:36:00)
Hello,
another solution for downloading whole books on Springerlink and save it to a pdf file is the Springerlink-Downloader: http://sebastiankusch.de/springerlink/
Grzz Sebastian
Comment by Brater (not verified) (2011-06-16 10:33:00)
If you don’t like python look here: http://code.google.com/p/springer-loader/ Easy to use!
Comment by Anonymous (not verified) (2011-05-19 20:59:00)
For those having problems running the script under Windows (7?), the problem is the findInPath def, which is called without the extension for iconv, pdftk and stapler (.exe). After adding this to all calls of findInPath the script works perfectly. I’m running it under Windows 7 with cygwin. Finding this problem has taken more than one hour … But was worth it. Maybe you could add an test for Windows and automatically add an “.exe” in this case.
Thanks for your work!
Comment by Blubbafett (not verified) (2012-05-15 18:52:00)
That is it! Thanks for your comment!
And many thanks to this project
Comment by Chris (not verified) (2011-05-02 12:32:00)
Thanks for your script!
Working fine with Cygwin / Windows 7 Don’t forget to install pdftk, iconv and imagemagick (for front cover convert) during setup. I also needed to run rebaseall (cygwin/bin/ash.exe -> bin/rebaseall) before python decided to work…
Comment by Anonymous (not verified) (2011-05-13 22:57:00)
Hi Chris, could you please explain what you did in detail? Because I try to make the script work for quite a while now, but I never worked with cygwin or python before. Although I installed pdftk and iconv I always get the errors that I have to install them. And if I comment them out, I get another error. Thanks in advance!
Comment by Anonymous (not verified) (2011-03-10 02:41:00)
Script is working fine here, thanks a lot!
Comment by exitus_ (not verified) (2011-04-04 02:13:00)
thx for the script! it did not work in the first place for me (arch linux, python2.7) but after messing up with the code (i’m not familiar with python..) it turned out i just had to change the first line:
#! /usr/bin/env python2.7
without this change i get this error:
this maybe because python uses the newest environment (3.2) if there is no version given. i hope this helps for some other users as well!
Comment by Anonymous (not verified) (2011-06-12 01:25:00)
i still get the same error even if i change the line, or what exactly did you do?
Comment by najmi (not verified) (2011-02-20 19:18:00)
Hi, I got this problem
What to do? Thanks!
Comment by Anonymous (not verified) (2011-03-28 00:36:00)
Hi, super Script, läuft ohne jegliche Probleme - vielen Dank für die Entwicklung!
Comment by horst (not verified) (2011-01-24 15:30:00)
Hallo, leider scheint das Skript mit der neuen Springerlink-Seite nicht (mehr) zu funktionieren:
Beim Aufruf via ./springer_download.py -l http://springerlink.com/content/978-3-8348-0645-1/contents/ (z.B.) erhalte ich den gleichen Fehler.
iconv und pdftk sind installiert.
Comment by Anonymous (not verified) (2011-03-30 13:28:00)
I have the same problem. I have python 2.7, I do downgrade to 2.6 version?
Comment by Manman (not verified) (2011-01-18 22:27:00)
kann mir bitte jemand helfen ich komme bei inconv nicht weiter ist installiert aber es funzt nicht.
Comment by Anonymous (not verified) (2011-01-18 22:24:00)
I hav a problem whit iconv can some one help me pls?
Comment by ขี้ไก่ (not verified) (2014-01-14 18:06:00)
Inspiring story there. What occurred after? Good luck!
Comment by Milian Wolff (2011-01-19 12:08:00)
Without an error description, no one will be able to help you. sigh how can people still post such lame support requests, I don’t get it…
Comment by Anonymous (not verified) (2011-02-15 22:30:00)
There are 10 kind of people. How can you still not get that?
Comment by Chris (not verified) (2010-11-17 22:21:00)
Great stuff, thank you!
Comment by Fruchtpfote (not verified) (2010-11-05 17:07:00)
On Lubuntu 10.10 I got the following error: “/usr/bin/env: python2: No such file or directory”
I had to change the first line of the script from “#! /usr/bin/env python2” to “#! /usr/bin/env python2.6”
The script worked very well! Thank you!
Comment by Frank (Germany) (not verified) (2010-10-12 16:19:00)
Hi,
i´m using yout great script in windows 7 with cygwin and pdftk. Downloadling works, but at the end, i get an error message:
-> “XXX” means in this case the title of the book and “…” the root directory of the springer_download script.
Can anyone help?
Comment by Katzenstreu (not verified) (2010-10-09 16:11:00)
Hi!
Can you help me? Waht seems to be the problem?
Comment by Katzenstreu (not verified) (2010-10-09 17:24:00)
Dieser Fehler trat bei ähnlichen Büchern nicht auf. Gib es Probleme die Datei anzulegen, wegen bestimmter Sonderzeichen? Der Download funktioniert. Das mergen wohl auch?! Aber das öffnen der Datei nicht, Zeile 43. Der gleiche Fehler beim Download mit der Option “-c” anstelle von “-l”. ich habe die zwei Tipps von Jochen (To fix the wrong order) in “mein” Skript eingebaut.
Grüße und danke vielmals für die tolle Arbeit!
Tim
Comment by Anonymous (not verified) (2010-09-02 00:11:00)
Hi,
I spot the problem with double-downloading of back-matter.pdf. As a result, 105-152 pp. are inserted right after the TOC, and also at the end of the document (after p.104, where it should be).
Example.
$ ./springer_download.py -c 978-1-84800-912-7 fetching book information… http://springerlink.com/content/978-1-84800-912-7/contents/
Now Trying to download book ‘A Topological Aperitif’
found 9 chapters downloading chapter 1/9 http://springerlink.com/content/978-1-84800-912-7/front-matter.pdf100% downloading chapter 2/9 http://springerlink.com/content/978-1-84800-912-7/back-matter.pdf 100% downloading chapter 3/9 http://springerlink.com/content/g1782312115308j1/fulltext.pdf 100% downloading chapter 4/9 http://springerlink.com/content/x37186361m57ju82/fulltext.pdf 100% downloading chapter 5/9 http://springerlink.com/content/h293v73635134064/fulltext.pdf 100% downloading chapter 6/9 http://springerlink.com/content/r7qk61576h587080/fulltext.pdf 100% downloading chapter 7/9 http://springerlink.com/content/n228263341064731/fulltext.pdf 100% downloading chapter 8/9 http://springerlink.com/content/g7763k24j248262q/fulltext.pdf 100% downloading chapter 9/9 http://springerlink.com/content/978-1-84800-912-7/back-matter.pdf 100% merging chapters book A Topological Aperitif was successfully downloaded, it was saved to /home/vitaliyb/springer/A_Topological_Aperitif.pdf
Best regards, Vitaly
Comment by kynan (not verified) (2010-08-26 10:42:00)
Awesome script! Exactly what I had been looking for for quite some time. I even started coding my own script in python, but only got it to sort-of work. Great job!
Comment by Anonymous (not verified) (2010-08-25 11:28:00)
Hi Ein sehr schönes skript. Ist es möglich das der Dateiname der Ausgabedatei auch den Autor enthält?
Comment by Timba (not verified) (2010-08-11 09:28:00)
Das Design von springerlink.com wurde umgestellt. Das Skript bricht sofort ab, da der Buchtitel nicht gefunden wird. Ein Buch wird nun über die isbn auffindbar —> http://www.springerlink.com/content/[isbn]/contents/
Die Funktionalität des Downloads einer Liste von Büchern ist deaktiviert (schade)..
Comment by Milian Wolff (2010-08-12 22:36:00)
should be fixed now.
Comment by Anonymous (not verified) (2010-08-13 16:22:00)
Almost fixed. You should change line 89 to: if match and match.group(2) and match.group(2).strip() != “”:
Cheers!
Comment by Milian Wolff (2010-08-15 17:02:00)
why?
Comment by Seb (not verified) (2010-08-17 16:09:00)
I just tried your great skript. Without the change suggested on the 13th about 30-40% of the tried books failed to download.
Comment by Milian Wolff (2010-08-18 14:50:00)
well, then I committed it - hope it helps.
thanks for the patch
Comment by Anonymous (not verified) (2010-08-20 09:39:00)
I tried the latest version of the script. But i determine that the order the chapters are downloaded and merged is not correct. At the moment the order is:
Why there is a Back-Matter just behind the Front-Matter? Could you please fix it?
Comment by jochen (not verified) (2010-08-29 11:59:00)
To fix the wrong order problem:
change the code from:
to:
I am not a pro coder, but it should fix this.
Comment by jochen (not verified) (2010-08-29 13:03:00)
To fix cover download change the following:
To:
Comment by Anonymous (not verified) (2010-08-22 10:03:00)
Hi,
thanks for this nice script. It worked for me till the new SpringerLink Webdesign.
With the latest script, i cant download e. g. this book: http://springerlink.com/content/x421j52q667r0077/
using this: /home/malte/Downloads/springer_download.py -l http://www.springerlink.com/content/x421lj52q667r0077/?sortorder=asc
And it doesnt word for any other book i tried. I dont have a version of your script before 13. august, so i even cant try to get 30 to 40 percent..
Malte
Comment by Seb (not verified) (2010-08-22 14:19:00)
Try using the ISBN instead, in your case ‘springer_download.py -c 978-3-540-24309-0’
Comment by Malte (not verified) (2010-08-22 18:38:00)
Hi,
thanks for your fast reply. But it doenst work for me.
root@malte-desktop:/home/malte# /home/malte/Desktop/springer_download.py -c 978-3-540-24309-0 fetching book information… http://springerlink.com/content/978-3-540-24309-0/
ERROR: Could not evaluate book title - bad link http://springerlink.com/content/978-3-540-24309-0/
Im using a VMWare Ubuntu system, and with old verison it worked very well. I can open the pdf file using my browser, so there is no llicense problem?
Malte
Comment by Seb (not verified) (2010-08-25 11:07:00)
For me it works with exactly the commandline you gave: Now Trying to download book ‘Elektronik für Ingenieure und Naturwissenschaftler’ I am not allowed to download the content, but it started downloading front- and backmatter. Do you use the newest version of the script?
Comment by Anonymous (not verified) (2010-06-08 15:49:00)
This script is a great idea and overall works very well!
I encountered one problem though that I was hoping to get some help with. I compiled a list of links to books I want to download and fed them into springer_download.py via a bash script so basically I could download my whole list one after the other, after a while I kept getting the same error asking if I had access to it no matter what book and no matter the access level (this is even after I included a minute inbetween books in the bash script by adding ‘sleep 60’) are you aware of what might be the cause of this issue?
Thanks!
Comment by Dierk E. (not verified) (2010-06-07 21:58:00)
danke für das Skript, funktioniert prima und spart viel Zeit!
Comment by Dierk E. (not verified) (2010-06-07 22:17:00)
Habe einen Fehler gefunden: wenn der generierte Dateiname Zeichen enthält, die auf dem verwendeten Dateisystem nicht erlaubt sind, wird eine Exception geworfen: enthält der Buchtitel und damit auch der Dateiname bspw. ein “ß”, so macht das Skript daraus ein Fragezeichen. Fragezeichen sind in Dateinamen auf FAT32-Dateisystemen aber nicht erlaubt. Vermutlich resultiert das Fragezeichen aus einer fehlerhaften Zeichendekodierung.
Comment by Dierk E. (not verified) (2010-06-10 13:20:00)
…außerdem versucht das Skript, Dateinamen mit enthaltenem Doppelpunkt anzulegen, was auf FAT32-Dateisystemen ebenfalls zu einem Fehler führt. Die nicht erlaubten Zeiche müssten vor Zeile 179 noch auch bookTitlePath entfernt werden.
Comment by Anonymous (not verified) (2010-05-20 01:14:00)
In my browser I can open the links to the chapters. Seemingly, the geturl function to download the chapters has no useragent set or something.
Comment by Anonymous (not verified) (2010-05-20 00:08:00)
Bei dem Buch hier: http://www.springerlink.com/content/t1166x/?p=1b42507155aa4d7387e1980dd0…
funktioniert es auch nicht mehr.
ERROR: downloaded chapter http://springerlink.com/content/q1n2783365424175/fulltext.pdf has invalid mime type text/html - are you allowed to download Funktionalanalysis Sechste, korrigierte Auflage 2007 - Springer Berlin Heidelberg?
bin aber eingeloggt und habe vpn, so dass ich das Buch manuell im browser anschauen und herunterladen kann
Comment by Tony (not verified) (2010-04-29 07:56:00)
My apologies for knowing nothing about Python, but is there an easy way to remove the pdftk part of the script and output all the individual pdfs? Combining the chapters is running into problems with books like this one:
http://springerlink.com/content/v12557/
It has the front-matter.pdf and back-matter.pdf files on every page which leads to a lot of repetition in the output. It would also be handy for those running under Mac OS X as it was a pain to build pdftk from source.
Comment by Anonymous (not verified) (2010-06-06 12:29:00)
there is an pre build version of pdftk avaible at http://www.accesspdf.com/pdftk/. Works like a charm for me (10.6.x) altough it’s built for 10.3 :D just some dylibs …
many thanks to milan for the great script! it comes really really handy some times!
Comment by Anonymous (not verified) (2010-06-05 02:23:00)
Well, python isn’t that hard to read. Just search for the term “pdftk” in the source-/script-file and comment it out (putting a hash-sign infront of the line), then run the script and see if an error comes up. If so, it will direct you to the line where it occurs, so you can investigate further. It’s really simple, try it out :)
Comment by Anonymous (not verified) (2010-04-21 20:52:00)
Anscheinen haben sie ihre Oberfläche geändert. Beispiel:
http://www.springerlink.com/content/l1x446/?p=79dea83afbc4473f8787e407e5…
Hier findet das Skript nur noch die vor und Rückseite. Die weiteren Kapitel sind in Unterkapitel eingeteilt. evtl. könnte ein findiger Programmiere das Skript anpassen?
Wäre ne super Sache!! Besten dank!
Comment by Anonymous (not verified) (2010-04-21 15:13:00)
Möchtest du das gesamte Angebot herunterladen? Das gestattet dir weder Springer noch deine Universität, es steht ja bereits das vollständige Herunterladen eines einzigen Buches in Konflikt mit den Nutzungsvereinbarungen.
Comment by Milian Wolff (2010-04-22 11:44:00)
Wo steht das denn, dass man nicht mal ein vollständiges Buch herunterladen darf? Und nein: Ich möchte natürlich nicht das gesamte Angebot herunterladen und habe das auch immer denjenigen gesagt, die nach etwas derartigem gefragt haben. Das ist völliger Schwachsinn.
Aber ich sehe nicht den Schaden, wenn man sich ein komplettes Buch herunterlädt? Ich muss zugeben, dass ich das auch ohne das Skript tun würde, um an die Bücher und Kapitel zu gelangen, die für eine Vorlesung erfordert werden.
Comment by Angelo (not verified) (2010-04-19 08:22:00)
Hallo Milian! Großartiges Skript! Läuft sehr sehr geil. Gibt es Ansätze bzw. Möglichkeiten das Skript derart zu erweitern, dass alle Bücher mit einer Befehlszeile runtergeladen werden können?
Viele Grüße aus Dortmund unter anderem von Jan S. :) Angelo
Comment by Anonymous (not verified) (2010-04-13 17:38:00)
Hallo, bei mir bleibt das Skript unter Ubuntu 8.04 beim downloaden immer irgendwo hängen (wie auch von Christian im Beitrag vom 02/22/2010).
Comment by Anonymous (not verified) (2010-04-13 20:04:00)
Hab es jetzt noch mehrmals probiert. Einmal hat es das Skript geschafft durchzulaufen ohne hängenzubleiben. War aber nur einmal wo es funktioniert hat bei etwa 20 Versuchen, dass selbe Buch zu downloaden. Ansonsten ist er immer hängen geblieben. Immer an unterschiedlichen Artikeln.
Comment by Anonymous (not verified) (2010-04-08 12:09:00)
Ja, es funktioniert plötzlich nicht mehr. Könnte der Autor das Script an die Veränderungen anpassen? Würde mich sehr freuen!
Comment by Anonymous 5 (not verified) (2010-03-25 14:56:00)
Sie haben so eine Art “Zwischenschicht” bei manchen Büchern. Das Script sucht scheinbar nur auf der initialen Buchseite nach *.pdf Links und lädt sie runter. Springerlink hat jetzt bei manchen Büchern jedes Kapitel noch in eine Art extra Ordner gepackt, wo jeweils nur noch mal die Frontmatter und das Kapitel drin ist (die nennen das dort Teil …). Das wird vom Script bisher nicht berücksichtigt.
Comment by Anonymous 2 (not verified) (2010-03-15 23:27:00)
Hallo,
kann es sein, dass auf der springerlink seite was geändert wurde? Hat bisher gut funktioniert. Scheint aber seit neuestem ein Problem zu haben.
Comment by Anonymous (not verified) (2010-03-13 17:27:00)
hi,
bei mir geht das tool nicht… glaub man muss sich jetzt einloggen. hat jemand eine alternerive? wär super
Comment by Matthias (not verified) (2010-03-12 05:43:00)
Hallo, danke für das Skript, konnte es bisher mangels VPN nicht testen, aufgrund der positiven Resonanz gehe ich aber davon aus, dass es bestens funktioniert. Auch ich wäre an einer Version interessiert, die Bookmarks erstellt und dazu die jeweils passende Beschreibung von Springerlink mit einbindet. Ein Programm zum erstellen von Bookmarks mit Linux ist JPdfBookmarks, Anleitung dazu gibts hier: http://jpdfbookmarks.altervista.org und das Programm selbst unter http://flavianopetrocchi.blogspot.com/2008/07/jpsdbookmarks-download-pag… Wäre super, wenn du das noch einbauen könntest, ich selber komme derzeit leider nicht dazu, habe hier einen eingeschränkten Internetzugang und kann das Programm nicht downloaden. Außerdem geht mein VPN nicht…
Grüße, Matthias
Comment by Seb (not verified) (2010-03-01 14:26:00)
I get an error as well “WindowsError: [Error 2] Das System kann die angegebene Datei nicht finden” what I can do?
The book you are trying to download is called ‘Word 2007’
found 14 chapters downloading chapter 1/14 http://www.springerlink.com/content/m5427g/front-matter.pdf 100% downloading chapter 2/14 http://springerlink.com/content/u838718169040815/fulltext.pdf 100% downloading chapter 3/14 http://springerlink.com/content/t347382q85766802/fulltext.pdf 100% downloading chapter 4/14 http://springerlink.com/content/rm4183k750h28k27/fulltext.pdf 100% downloading chapter 5/14 http://springerlink.com/content/q25m417372705567/fulltext.pdf 100% downloading chapter 6/14 http://springerlink.com/content/t7303462187j3t17/fulltext.pdf 100% downloading chapter 7/14 http://springerlink.com/content/n191l36489484284/fulltext.pdf 100% downloading chapter 8/14 http://springerlink.com/content/wp7t1657u28p4774/fulltext.pdf 100% downloading chapter 9/14 http://springerlink.com/content/l3126077869171g2/fulltext.pdf 100% downloading chapter 10/14 http://springerlink.com/content/j6399r4330572128/fulltext.pdf 100% downloading chapter 11/14 http://springerlink.com/content/p2262884852pl1w4/fulltext.pdf 100% downloading chapter 12/14 http://springerlink.com/content/u647377241368kl7/fulltext.pdf 100% downloading chapter 13/14 http://springerlink.com/content/t5h400553644360l/fulltext.pdf 100% downloading chapter 14/14 http://www.springerlink.com/content/m5427g/back-matter.pdf 100% merging chapters Traceback (most recent call last): File “C:\Dokumente und Einstellungen\Sebastian\Desktop\sp\springer_download.py”, line 238, in main(sys.argv[1:]) File “C:\Dokumente und Einstellungen\Sebastian\Desktop\sp\springer_download.py”, line 147, in main p1 = subprocess.Popen([“echo”, bookTitle], stdout=subprocess.PIPE) File “D:\Python26\lib\subprocess.py”, line 621, in **init** errread, errwrite) File “D:\Python26\lib\subprocess.py”, line 830, in _execute_child startupinfo) WindowsError: [Error 2] Das System kann die angegebene Datei nicht finden
Comment by Milian Wolff (2010-03-01 20:07:00)
I don’t know, I won’t support Windows. Try cygwin as the poster above you said that it works.
Comment by Anonymous (not verified) (2010-02-24 20:31:00)
Ich wollte nur mal rückmelden, dass das Skript mit Cygwin unter Windows 7 hervorragend und ohne Probleme arbeitet. Bei der Installation von Cygwin muss man natürlich darauf achten, die entsprechenden Pakete auszuwählen. Ein großes Danke an den Autor für die Arbeit!
Comment by Katzenstreu (not verified) (2010-10-01 19:29:00)
Kannst du sagen, welche Pakete benötigt werden? Im Internet fand ich leider keine Hilfe.
Comment by Christian (not verified) (2010-02-22 17:26:00)
Nachdem ich es ja unter Windows teilweise zum laufen bekommen habe sind das meine ersten gehversuche mit Linux, aber trotzdem lädt er es nicht runter…. (VPN ist aktiviert)
vll kann mir ja jemand einen Tipp geben.
^^ hier an der stelle hängt er
Comment by RS(15,11) (not verified) (2010-02-05 20:54:00)
Hallo, bin alter Windows Benutzer und hab mich seit gestern auch wegen deinem Skript in Unix eingearbeitet. Benutze nun Cygwin und mit der neuesten Version des Skriptes läuft alles super. Vielen Dank!!
Comment by Vitaly (not verified) (2010-02-03 01:50:00)
Hi,
thank you for this script.
Since about a week ago, it stopped working though:
………………………………….
$ ./springer_download.py -l http://www.springerlink.com/content/qv89j2/?p=101a335b740a47c7a7578b7d16…
$ Please wait, link source is being downloaded… http://www.springerlink.com/content/qv89j2/
ERROR: Could not evaluate book title - bad link?
Usage: springer_download.py [OPTIONS]
Options: -h, —help Display this usage message -l LINK, —link=LINK defines the link of the book you intend to download -c HASH, —content=HASH builds the link from a given HASH (see below)
………………………………….
This error appears for whatever book I try to download. Is it because they changed directory structure or something else @ Springer?
Thank you, Vitaly
Comment by Milian Wolff (2010-02-03 16:01:00)
Thanks for the heads up, I fixed the code to circumvent this springerlink “protection” (it didn’t accept the default UserAgent that was sent by python…). Should work properly now (assuming you have the rights to access this book, which I / the FU-Berlin) hast not it seems.
Comment by Vitaly (not verified) (2010-02-12 08:47:00)
By the way, I spotted another glitch: if the book name contains the colon sign (‘:’), the book is downloaded OK but cannot be saved, as file name cannot include colons. You could substitute it with dash or something…
Comment by Milian Wolff (2010-02-12 13:59:00)
Can you give me an example? I don’t see why a colon should be removed from a filename, it’s perfectly valid imo. At least on Unix:
Comment by Vitaly (not verified) (2010-02-12 08:38:00)
Thanks a lot for prompt response, Milian! It works great now.
Comment by Thomas (not verified) (2010-02-04 16:03:00)
Hi, erstmal danke für das Script, ich benutze es schon ziemlich lange…Ich habe jetzt allerdings auch Probleme beim downloaden. Ich bekomme folgende Fehlermeldung:
Please wait, link source is being downloaded…
http://www.springerlink.de/content/q28652/
The book you are trying to download is called ‘Regelungstechnik 1’
found 15 chapters
downloading chapter 1/15
http://www.springerlink.de/content/q28652/front-matter.pdf -819200%
ERROR: downloaded chapter http://www.springerlink.de/content/q28652/front-matter.pdf has invalid mime type text/html - are you allowed to download it?
“Per Hand” kann ich die pdfs der einzelnen Kapitel allerdings problemlos herunterladen.
Comment by Milian Wolff (2010-02-05 00:01:00)
Hm dann stimmt wohl noch was nicht - muss ich mir mal anschauen. Evtl. wird noch der Referer gecheckt oder sowas - mal gucken was die Leute von SpringerLink sich da ausdenken um es uns Studenten zu erschweren an die Bücher zu kommen… seufz
Comment by Thomas (not verified) (2010-02-05 13:35:00)
Ich habe mal was probiert, scheint sogar geklappt zu haben :)
Ich habe nur oben das hinzugefügt:
Und die def geturl(url, dst) geändert in:
Comment by Milian Wolff (2010-02-05 14:16:00)
Great, thanks for the patch. I included it now (slightly different). Does it work with the vanilla source from github again now? I ask since I can still not download that one book ;-)
Comment by pappy (not verified) (2009-08-11 14:55:00)
i can’t download with script now, error here
“Please wait, link source is being downloaded… http://springerlink.com/content/f54k582l0w11xj18/
The book you are trying to download is called ‘Architecture of an LBS Platform to Support Privacy Control for Tracking Moving Objects in a Ubiquitous Environments’
found 1 chapters downloading chapter 1/1 http://springerlink.com/content/f54k582l0w11xj18/fulltext.pdf 100%
ERROR: downloaded chapter http://springerlink.com/content/f54k582l0w11xj18/fulltext.pdf has invalid mime type text/html - are you allowed to download it? “
Plz help :(
Comment by Milian Wolff (2009-08-11 15:18:00)
You need to be authenticated for SpringerLink via VPN. This script does not support any other authentication.
I myself use it from my university where access to springerlink is automatically authenticated. If it is the same for your university, access one of the servers there and run the script from there. Ask your IT department.
Comment by moohh (not verified) (2010-02-03 23:18:00)
I am authenticated via VPN and I can manually download the books by using Firefox, but if I want to try this script, I get the same error.
The download of a single pdf via wget doesn’t work either. I got ERROR 403.
Comment by Milian Wolff (2010-02-04 00:45:00)
update the script, I fixed that a few hours ago.
Comment by Anonymous (not verified) (2010-07-12 19:06:00)
Nevermind, I figured it out. Springer doesn’t like wget, so you need to fake the browser id using -U ‘Mozilla/5.0’
Comment by Anonymous (not verified) (2010-07-12 18:25:00)
Milian,
Thanks for the script. Can you give some insight on how you fixed the 403 error when wget’ing a single PDF?
I’m trying to do something similar and can’t get past this issue …
Comment by Anonymous (not verified) (2009-07-30 17:01:00)
Habe Cygwin installiert, darin läuft es. Habe nur bezüglich iconv auf Folgendes abgeändert:
p2 = subprocess.Popen([“iconv”, “-f”, “UTF-8”, “-t” ,”CP1258”],
Umlaute kommen dann komisch und es gibt ein Problem wenn Fragezeichen drin sind (im Dateinamen)
Eine andere Schwierigkeit kommt auf, wenn ein Buch aus mehreren Untervolumes besteht, da versagt dann das downloaden.
Das Skript ist genial gemacht, besten Dank an den Autor!
Comment by Christian (not verified) (2009-07-27 23:49:00)
Hey, tolles Script! Ich habe versucht es unter Windows zum laufen zu bekommen - und es auch geschafft!!! Musste jedoch die beiden Abfragen ob pdftk und iconv vorhanden sind abschalten. Beide gibt es für Windows und ich habe sie so integriert, dass sie Platformweit aufrufbar sind.
Herunterladen funktioniert, jedoch folgendes Problem:
Woran scheitert die weitere Verarbeitung? LG
Comment by Milian Wolff (2009-07-28 01:51:00)
Naja, ich will den Namen in iconv pipen, weiß nicht ob das auf Windows überhaupt geht. Notfalls einfach auskommentieren und damitleben, dass der dir ggf. versucht ne Datei anzulegen die “ungute” Zeichen im Namen enthält… Oder nen anderen Weg finden iconv unter Windows aufzurufen (ohne echo). Oder vlt. mingw installieren - könnte gehen…
Comment by Anonymous (not verified) (2009-06-02 02:43:00)
What about a Windows compatible script to allow download of articles from journals in an organized fashion? Thanks for ur consideration
Comment by Milian Wolff (2009-06-02 12:59:00)
I don’t use Windows and won’t make the script windows-compatible. Yet I’d happily accept patches. Since python is cross- platform it should’nt be too hard. You’d just have to find alternatives to pdftk and iconv. These two dependencies make the script platform dependent.
Comment by flo (not verified) (2009-04-08 19:29:00)
hi milian!
ich hab mal schnell ne “just HASH” option eingefügt, wenn du willst ..
is keine “schöne” lösung, aber ging schnell ^^
Ansonsten, großartig dein Skript!
Comment by Milian Wolff (2009-04-08 20:32:00)
Hab grad deinen Patch, leicht verändert, zu github geschoben. Danke :)
~~~
just pushed a commit to github with your patch (slightly modified). Thanks!
Comment by Anonymous (not verified) (2009-04-04 16:37:00)
Thanks for the quick reply. I think the problem is the university firewall which seems to be blocking the traffic as I can use the script from outside the university. One suggestion is to make this work as a firefox plugin (perhaps with imacros). Thanks for the useful script!
Comment by Anonymous (not verified) (2009-04-03 19:55:00)
Hello. This software is an excellent idea but I get the following error:
4]# ./springer_download.py -l “http://www.springerlink.com/content/h381wp/?sortorder=asc&v=expanded” Please wait, link source is being downloaded… http://www.springerlink.com/content/h381wp/
ERROR: Bad link given ([Errno socket error] (110, ‘Connection timed out’))
The springerlink address is correct because I can paste it into a browser and both the webpage and the pdfs open up properly. I’m using andlinux which runs ubuntu as a service in windows vista. This could be the cause of the problem but the browser, Synaptic Package Manager and pinging from the console work. I’ve also tried to disable my firewall but this did not fix the problem. Thanks in advance for any insight into this problem.
Comment by Milian Wolff (2009-04-03 20:40:00)
I think I know what is the cause yet can’t test it myself right now. Try with the following link:
http://www.springerlink.com/content/h381wp/?sortorder=asc
Note the different layout of the page, I think that’s the cause. Hope that helps.
Comment by Anonymous (not verified) (2009-03-16 21:20:00)
Sehr gut - genau was ich gesucht habe! Danke!
weitere Wünsche:
Comment by Milian Wolff (2009-03-16 22:29:00)
Beides nicht wirklich möglich, da man dafür die PDFs bearbeiten müsste. Und PDF ist mehr oder weniger ein Read-Only- Dateiformat.
Comment by Anonymous (not verified) (2010-01-04 13:33:00)
Und was wäre wenn man die einzelnen Kapitel mit Namen als Bookmarks in das endgültige PDF einfügen könnte? Ginge das?
Comment by Milian Wolff (2010-01-04 17:11:00)
Find es raus, ich hab keine Ahnung von PDF-Authoring.
Comment by Matthias (not verified) (2010-03-12 05:42:00)
Hallo, danke für das Skript, konnte es bisher mangels VPN nicht testen, aufgrund der positiven Resonanz gehe ich aber davon aus, dass es bestens funktioniert. Auch ich wäre an einer Version interessiert, die Bookmarks erstellt und dazu die jeweils passende Beschreibung von Springerlink mit einbindet. Ein Programm zum erstellen von Bookmarks mit Linux ist JPdfBookmarks, Anleitung dazu gibts hier: http://jpdfbookmarks.altervista.org und das Programm selbst unter http://flavianopetrocchi.blogspot.com/2008/07/jpsdbookmarks-download-pag… Wäre super, wenn du das noch einbauen könntest, ich selber komme derzeit leider nicht dazu, habe hier einen eingeschränkten Internetzugang und kann das Programm nicht downloaden. Außerdem geht mein VPN nicht…
Grüße, Matthias