Skip to content

Commit

Permalink
fixed des bug du panier
Browse files Browse the repository at this point in the history
  • Loading branch information
Pmaioranool committed Feb 13, 2024
1 parent f486120 commit 26a4945
Show file tree
Hide file tree
Showing 37 changed files with 109 additions and 7 deletions.
6 changes: 0 additions & 6 deletions JS/envoi_panier.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,7 @@ const idProduitSelectionner = reponse.find((element) => element._id === id);

const btn_envoyerPanier = document.querySelectorAll("#btn-envoyer");

btn_envoyerPanier.forEach((button) => {
button.addEventListener("click", () => {
let newUrl = button.attributes["0"].nodeValue;

window.location.href = newUrl;
});
});

btn_envoyerPanier.forEach((button) => {
button.addEventListener("click", () => {
Expand Down
3 changes: 3 additions & 0 deletions html/bureau gaming.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/casque gaming.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/casque xbox.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/clavier.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/enceinte gaming.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/fauteuil gaming.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/manette xbox elite.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/manette xbox series x et s.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/nintendo 3ds.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/nintendo 64.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/nintendo ds.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/nintendo gamecube.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/nintendo switch.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/nintendo wii u.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/nintendo wii.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/nintendo.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Nintendo</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
5 changes: 4 additions & 1 deletion html/panier.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Panier</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand All @@ -21,7 +24,7 @@ <h1>Site E-commerce pour consoles vidéo</h1>
</nav>
<main>
<section id="basket" class="flex-column-centre">
<div id="blocTitrePanier" class="flex-start size80">
<div id="container-produits-panier" class="flex-start size80">

</div>
<div id="basket-items" class="flex-column-center">
Expand Down
3 changes: 3 additions & 0 deletions html/pc.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PC</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/playstation 1.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/playstation 2.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/playstation 3.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/playstation 4.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/playstation 5.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/playstation vr.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/playstation.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/ps vita.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/psp.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/souris gaming.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/super nintendo classic.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/tapis de souris gaming.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/xbox 360.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/xbox one x.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/xbox one.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/xbox series s.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/xbox series x.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>PlayStation</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down
3 changes: 3 additions & 0 deletions html/xbox.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Xbox</title>
<link rel="stylesheet" href="../css/style.css" />
<script src="../JS/articles.js" defer></script>
<script src="../JS/envoi_panier.js" defer></script>
<script src="../JS/panier.js" defer></script>
</head>
<body>
<header>
Expand Down

0 comments on commit 26a4945

Please sign in to comment.