Réorganisation du code
This commit is contained in:
29
templates/404.html
Normal file
29
templates/404.html
Normal file
@@ -0,0 +1,29 @@
|
||||
<!--<head>-->
|
||||
<!-- <meta charset="UTF-8">-->
|
||||
<!-- <link rel="stylesheet" href="static/css/style.css", filename= 'style.css'>-->
|
||||
<!-- <title>SpotDL Web</title>-->
|
||||
<!--</head>-->
|
||||
|
||||
<!--<body>-->
|
||||
<!-- <div class="container">-->
|
||||
<!-- <h1>Error 404</h1>-->
|
||||
<!-- <h2>Il semble que vous soyez perdu. Revenez à la page d'accueil</h2>-->
|
||||
<!-- <button class="btn" onclick="window.location.href = '/';">Accueil</button>-->
|
||||
<!-- </div>-->
|
||||
|
||||
<!--</body>-->
|
||||
|
||||
{% extends 'layout.html' %}
|
||||
|
||||
{% block body %}
|
||||
|
||||
<body>
|
||||
<div class="container">
|
||||
<h1>Error 404</h1>
|
||||
<h2>Il semble que vous soyez perdu. Revenez à la page d'accueil</h2>
|
||||
<button class="btn" onclick="window.location.href = '/';">Accueil</button>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
|
||||
{% endblock body %}
|
||||
@@ -1,10 +0,0 @@
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<link rel="stylesheet" href="{{ url_for('static', filename= 'css/style.css') }}">
|
||||
<title>SpotDL Web</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1> SpotDL Web </h1>
|
||||
<h2> Téléchargement Terminé </h2>
|
||||
<button onclick="window.location.href = '/';">Télécharger à nouveau</button>
|
||||
</body>
|
||||
@@ -1,13 +1,37 @@
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<link rel="stylesheet" href="{{ url_for('static', filename= 'css/style.css') }}">
|
||||
<title>SpotDL Web</title>
|
||||
</head>
|
||||
<!--<head>-->
|
||||
<!-- <meta charset="UTF-8">-->
|
||||
<!-- <link rel="stylesheet" href="static/css/style.css", filename= 'style.css'>-->
|
||||
<!-- <title>SpotDL Web</title>-->
|
||||
<!--</head>-->
|
||||
|
||||
<h1> SpotDL Web </h1>
|
||||
<h2> Veuillez entrer au moins une URL ! </h2>
|
||||
<button onclick="window.location.href = '/';">Télécharger à nouveau</button>
|
||||
<!--<body>-->
|
||||
<!-- <div class="container">-->
|
||||
<!-- <h1 class="title"> SpotDL Web </h1>-->
|
||||
<!-- <h2> Veuillez entrer au moins une URL ! </h2>-->
|
||||
<!-- <button class="btn" onclick="window.location.href = '/';">Accueil</button>-->
|
||||
|
||||
{% if message %}
|
||||
<p>{{ message }}</p>
|
||||
{% endif %}
|
||||
<!-- {% if message %}-->
|
||||
<!-- <p>{{ message }}</p>-->
|
||||
<!-- {% endif %}-->
|
||||
<!-- </div>-->
|
||||
|
||||
<!--</body>-->
|
||||
|
||||
{% extends 'layout.html' %}
|
||||
|
||||
{% block body %}
|
||||
|
||||
<body>
|
||||
<div class="container">
|
||||
<h1 class="title"> SpotDL Web </h1>
|
||||
<h2> Veuillez entrer au moins une URL ! </h2>
|
||||
<button class="btn" onclick="window.location.href = '/';">Accueil</button>
|
||||
|
||||
{% if message %}
|
||||
<p>{{ message }}</p>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
</body>
|
||||
|
||||
{% endblock body %}
|
||||
18
templates/finish.html
Normal file
18
templates/finish.html
Normal file
@@ -0,0 +1,18 @@
|
||||
{% extends 'layout.html' %}
|
||||
|
||||
{% block body %}
|
||||
|
||||
<body>
|
||||
<div class="container">
|
||||
<h1 class="title"> SpotDL Web </h1>
|
||||
<h2> Téléchargement terminé </h2>
|
||||
<button class="btn" onclick="window.location.href = '/';">Accueil</button>
|
||||
|
||||
{% if message %}
|
||||
<p>{{ message }}</p>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
</body>
|
||||
|
||||
{% endblock body %}
|
||||
47
templates/index.html
Normal file
47
templates/index.html
Normal file
@@ -0,0 +1,47 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<link rel="stylesheet" href="static/css/style.css" , filename= 'style.css'>
|
||||
<script src="/static/js/script.js"></script>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title>SpotDL Web</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div class="container">
|
||||
<h1 class="title">SpotDL Web</h1>
|
||||
<div class="bordered">
|
||||
<p>
|
||||
<h3>Procédure</h3>
|
||||
<ul>
|
||||
<li>Se rendre sur Spotify en cliquant <a rel="stylesheet" href="https://open.spotify.com/" target="_blank">ici</a></li>
|
||||
<li>Chercher un Album ou une Playlist</li>
|
||||
<li>Sur Ordinateur : À droite du coeur, cliquez sur ... puis Partager et Copier le lien vers (Album ou Playlist)</li>
|
||||
<li>Sur Smartphone : Cliquez sur le logo de partage puis Copier le lien</li>
|
||||
</ul>
|
||||
<p>
|
||||
</div>
|
||||
<form action="/download" method="POST">
|
||||
<div class="form-group">
|
||||
<input type="text" class="form-control" name="url1" id="url1" pattern="^https://open\.spotify\.com/(?:album|playlist|track)/[\w-]+(?:\?si=[\w-]+)?$" placeholder="Entrez l'URL d'une Piste, d'un Album ou d'une Playlist">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<input type="text" class="form-control" name="url2" id="url2" pattern="^https://open\.spotify\.com/(?:album|playlist|track)/[\w-]+(?:\?si=[\w-]+)?$" placeholder="Entrez l'URL d'une Piste, d'un Album ou d'une Playlist">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<input type="text" class="form-control" name="url3" id="url3" pattern="^https://open\.spotify\.com/(?:album|playlist|track)/[\w-]+(?:\?si=[\w-]+)?$" placeholder="Entrez l'URL d'une Piste, d'un Album ou d'une Playlist">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<input type="text" class="form-control" name="url4" id="url4" pattern="^https://open\.spotify\.com/(?:album|playlist|track)/[\w-]+(?:\?si=[\w-]+)?$" placeholder="Entrez l'URL d'une Piste, d'un Album ou d'une Playlist">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<input type="text" class="form-control" name="url5" id="url5" pattern="^https://open\.spotify\.com/(?:album|playlist|track)/[\w-]+(?:\?si=[\w-]+)?$" placeholder="Entrez l'URL d'une Piste, d'un Album ou d'une Playlist">
|
||||
</div>
|
||||
<button type="submit" class="btn" id="download-button" onclick="startDownload()">Télécharger</button>
|
||||
<button type="reset" class="btn" id="refresh-button" onclick="refreshPage()">Rafraîchir</button>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
16
templates/layout.html
Normal file
16
templates/layout.html
Normal file
@@ -0,0 +1,16 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="fr">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<link rel="stylesheet" href="./static/css/style.css", filename= 'style.css'>
|
||||
<script src="/static/js/script.js"></script>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title>SpotDL Web</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
{% block body %}{% endblock body %}
|
||||
|
||||
</body>
|
||||
</html>
|
||||
7
templates/modele.html
Normal file
7
templates/modele.html
Normal file
@@ -0,0 +1,7 @@
|
||||
{% extends 'layout.html' %}
|
||||
|
||||
{% block body %}
|
||||
|
||||
|
||||
|
||||
{% endblock body %}
|
||||
@@ -1,45 +0,0 @@
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<link rel="stylesheet" href="{{ url_for('static', filename= 'css/style.css') }}">
|
||||
<title>SpotDL Web</title>
|
||||
</head>
|
||||
|
||||
<h1>SpotDL Web</h1>
|
||||
<div class="url">
|
||||
<form method="POST">
|
||||
<!-- <label for="url">URL:</label>
|
||||
<input type="text" name="url" id="url"> -->
|
||||
|
||||
<div style="margin-top: 10px;">
|
||||
<label for="url1">URL 1:</label>
|
||||
<input type="text" name="url1" id="url1">
|
||||
</div>
|
||||
|
||||
<div style="margin-top: 10px;">
|
||||
<label for="url2">URL 2:</label>
|
||||
<input type="text" name="url2" id="url2">
|
||||
</div>
|
||||
|
||||
<div style="margin-top: 10px;">
|
||||
<label for="url3">URL 3:</label>
|
||||
<input type="text" name="url3" id="url3">
|
||||
</div>
|
||||
|
||||
<div style="margin-top: 10px;">
|
||||
<label for="url4">URL 4:</label>
|
||||
<input type="text" name="url4" id="url4">
|
||||
</div>
|
||||
|
||||
<div style="margin-top: 10px;">
|
||||
<label for="url5">URL 5:</label>
|
||||
<input type="text" name="url5" id="url5">
|
||||
</div>
|
||||
|
||||
<div style="margin-top: 10px;">
|
||||
<input type="submit" value="Téléchargement">
|
||||
</div>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user