A tool to download your books from Zanichelli into PDFs.
THIS DOES NOT WORK WITH BOOKS FROM BOOKTAB, FOR THAT PLEASE CHECK https://github.com/Leone25/booktab-downloader
- Node >= 14.0
- Windows 10 or higher (The script hasn't been tested on other platforms, but it may work, you will likely have issues on mac os)
- A modern browser (Chrome, Edge, Firefox ...)
- Download the source code from here or click the above green button
Code
and clickDownload Zip
- Extract the zip file in a new folder and open it
- Open the folder in a terminal
- If you are on Windows 11, just right click and press
Open with Windows Terminal
- If you are on Windows 10, hold
shift
on your keyboard and right click on a white space, then pressOpen command window here
- If you are on Windows 11, just right click and press
- Type in the terminal:
npm i
-
Open https://my.zanichelli.it in your browser and open the menu of the book you'd like to download and open the web reader
-
Open the dev tools (
f12
works), navigate to the network page in the dev tools and make sure that caching is disabled and that permanent log is enabled, then refresh the page -
In the developer tools open the console and copy
window.angularComponentRef.render.settings.encResource
and press enter, if the result is notundefined
, then copy the output string (without any quotes) -
Open the folder in a terminal (as described above) and run the script with node typing:
node .
-
If in step 3 you've got
undefined
sayn
and skip the next step, elsey
-
Paste they encryption key you have obtained and press enter
-
Go back to the developers tools and now look in the network tab, find the file
content.opf
and click on it -
It should now display the full url of the file and some other information (you may need to click on the headers sub-tab)
-
From the displayed url copy the
ebookID
, which is a number repeated 2 times in the url, and paste it in the terminal and press enter -
Scroll down in the file information (back in the network page) and find where it says
Cookie:
, select everything after that (be aware, on firefox you'll need to toggle "Raw" to see the full header, as with long values they get shortened), copy and paste it in the terminal -
Wait, the book will be downloaded and saved to the script' directory
NOTE: You will have to do again all the steps if you want to download another book, the encryption key is different for every book
Remember that you are responsible for what you are doing on the internet and even tho this script exists it might not be legal in your country to create personal backups of books.
I may or may not update this script depending on my needs, but I'm open to pull requests ecc.
This software uses the MIT License