Feb 16, 2015 10:32 AM
(This post was last modified: Feb 16, 2015 10:34 AM by 0fftime.)
Hi there!
I've got a request, and was wondering if anyone here could help me out!
This year my school introduced digital books, which in my opinion is quite awesome however, since the licences are digital ones I can only access the books this year. And if I would like to study from it next year or use it as reference I can't. But today I found out that the every single page of the book is a simple png or jpg file. Which even can be accessed without logging into the site of publisher. And since I've just started to learn python (via Learn Python the Hard Way) I thought a python script could help.
What I would like a script a to do is use a certain URL and download the image, the URL is a straight link to the IMG file (which can either be .png or .jpg). And then progress to the next URL by itself. So for instance I would give the URL http://www.google.com/page001.jpg and the script would download that image to a given folder. After that it would go to the next one itself which would be http://www.google.com/page002.jpg. And so on till it ends.
After this I would like to combine all these images in an ebook so that I can easily read through it.
What i think could be a problem that with most books some pages are in .jpg format and others are in .png. This is completely random. That might become a problem with checking the URL's.
Now my question is if someone could be able to help me make this or has something like this available. My python programming knowledge is not that great since I've just started learning, so making this all myself would be kind of a challenge. I would however like to learn from this so that I might be able to fix this kind of issue myself.
Thanks in advance,
0fftime
I've got a request, and was wondering if anyone here could help me out!
This year my school introduced digital books, which in my opinion is quite awesome however, since the licences are digital ones I can only access the books this year. And if I would like to study from it next year or use it as reference I can't. But today I found out that the every single page of the book is a simple png or jpg file. Which even can be accessed without logging into the site of publisher. And since I've just started to learn python (via Learn Python the Hard Way) I thought a python script could help.
What I would like a script a to do is use a certain URL and download the image, the URL is a straight link to the IMG file (which can either be .png or .jpg). And then progress to the next URL by itself. So for instance I would give the URL http://www.google.com/page001.jpg and the script would download that image to a given folder. After that it would go to the next one itself which would be http://www.google.com/page002.jpg. And so on till it ends.
After this I would like to combine all these images in an ebook so that I can easily read through it.
What i think could be a problem that with most books some pages are in .jpg format and others are in .png. This is completely random. That might become a problem with checking the URL's.
Now my question is if someone could be able to help me make this or has something like this available. My python programming knowledge is not that great since I've just started learning, so making this all myself would be kind of a challenge. I would however like to learn from this so that I might be able to fix this kind of issue myself.
Thanks in advance,
0fftime

