diff --git a/index.html b/index.html index ba1452d..4d93e6e 100644 --- a/index.html +++ b/index.html @@ -71,6 +71,19 @@ </div> </div> + <div> + <h1>Liens rapides :</h1> + <button onclick="changerURL(9782091317243, 'nathan')"> + <h1>Maths Ex</h1> + </button> + <button onclick="changerURL(9782091317113, 'nathan')"> + <h1>Maths Spe</h1> + </button> + <!-- <button onclick="changerURL(9782017102120, 'hachette')"> + <h1></h1> + </button> --> + </div> + <!-- <div> <h1>Liens rapides :</h1> <button onclick="changerURL(9782017102106, 'hachette')"> @@ -221,12 +234,10 @@ else if (editionchoisie == 'nathan') { console.log("nathan"); document.getElementById("editionesthcoisieest").innerHTML = ""; - diviframe.style.display = ''; + diviframe.style.display = 'none'; slider.style.display = ''; - divimg.style.display = 'none'; + divimg.style.display = ''; divserver.style.display = 'none'; - document.documentElement.style.setProperty('--iframe-width', '1152px'); - document.documentElement.style.setProperty('--iframe-height', '1594px'); } else { document.getElementById("editionesthcoisieest").innerHTML = "⚠ Cette édition n'est pas encore supportée ⚠"; @@ -298,8 +309,8 @@ iframe2.src = newUrl2; } else if (editionchoisie == 'nathan') { - var newUrl1 = "https://raw.githubusercontent.com/NohamR/Manuelcontent/main/Nathan/" + code + "/page0.jpg"; - var newUrl2 = "https://raw.githubusercontent.com/NohamR/Manuelcontent/main/Nathan/" + code + "/page1.jpg"; + var newUrl1 = "https://raw.githubusercontent.com/NohamR/Manuelcontent/main/Nathan/" + code + "/page1.jpg"; + var newUrl2 = "https://raw.githubusercontent.com/NohamR/Manuelcontent/main/Nathan/" + code + "/page2.jpg"; img1.src = newUrl1; img2.src = newUrl2; } diff --git a/py/nathan/get.py b/py/nathan/get.py index 17a9156..8881630 100644 --- a/py/nathan/get.py +++ b/py/nathan/get.py @@ -8,7 +8,7 @@ import re def getimg(url, nb): response = requests.get(url) if response.status_code == 200: - save_path = f"9782091317243/{nb}.jpg" + save_path = f"9782091317113/{nb}.jpg" with open(save_path, 'wb') as file: file.write(response.content) print(f"The image has been saved as '{save_path}'") @@ -16,8 +16,8 @@ def getimg(url, nb): print(f"Failed to download the image. Status code: {response.status_code}") -url = 'https://biblio.nathan.fr/epubs/web/4ebeff9ce5eb568f8142771fdac580b8aeb12f675d75fa4c1ebb4620050d6c01842394910eeee327/NATHAN/bibliomanuels/distrib_gp/2/1/10300/online/OEBPS/TOC.xhtml' -debut = 'https://biblio.nathan.fr/epubs/web/4ebeff9ce5eb568f8142771fdac580b8aeb12f675d75fa4c1ebb4620050d6c01842394910eeee327/NATHAN/bibliomanuels/distrib_gp/2/1/10300/online/OEBPS/' +url = 'https://biblio.nathan.fr/epubs/web/4ebeff9ce5eb568f8142771fdac580b8aeb12f675d75fa4c1ebb4620050d6c01842394910eeee327/NATHAN/bibliomanuels/distrib_gp/2/1/10366/online/OEBPS/TOC.xhtml' +debut = 'https://biblio.nathan.fr/epubs/web/4ebeff9ce5eb568f8142771fdac580b8aeb12f675d75fa4c1ebb4620050d6c01842394910eeee327/NATHAN/bibliomanuels/distrib_gp/2/1/10366/online/OEBPS/' r = requests.get(url) soup = BeautifulSoup(r.text, 'html.parser') pagelist = soup.find('nav', {'epub:type': 'page-list'})