Explorar o código

Retour du texte autour du résultat de l'API

Guichen %!s(int64=4) %!d(string=hai) anos
pai
achega
4272cf768c
Modificáronse 3 ficheiros con 36 adicións e 4 borrados
  1. 16 1
      apiTableauFromClassement.php
  2. 17 1
      apiTableauFromNote.php
  3. 3 2
      composer.json

+ 16 - 1
apiTableauFromClassement.php

@@ -24,7 +24,22 @@ if ($isClassementValid) {
 	$rangMoyen = (int) $_GET["classement"];
 	// HTML renvoyé au site
 	$html = <<<EOF
+<!doctype html>
+<html lang="fr">
+<head>
+	<meta charset="UTF-8">
+	<meta name="viewport"
+	      content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
+	<meta http-equiv="X-UA-Compatible" content="ie=edge">
+	<title>RangLimier</title>
 	<link rel="stylesheet" href="assets/bootstrap.min.css">
+	<link rel="stylesheet" href="assets/divers.css">
+</head>
+<body>
+	<h1>RangLimier</h1>
+	<p>Cet outil permet, en entrant un classement (réel ou supposé), de voir les choix disponibles à ce classement. <br>
+	<i>Attention : Cet outil est à but purement indicatif, les variations entre chaque année sont imprévisibles. Cela vous sert à avoir une vision globale des choix possible</i>
+	</p>
 	<style>
 	/* Tableau */
 		table {
@@ -173,7 +188,7 @@ EOF;
 		$html .= "</tr>";
 	}
 	
-	$html .= "</tbody></table><br>";
+	$html .= "</tbody></table><br></body>";
 	
 	// Affichage du HTML demandé
 	echo $html;

+ 17 - 1
apiTableauFromNote.php

@@ -78,6 +78,22 @@ if ($isNoteValid && $isAnneeValid) {
 	
 	// HTML renvoyé au site
 	$html = <<<EOF
+	<!doctype html>
+	<html lang="fr">
+	<head>
+		<meta charset="UTF-8">
+		<meta name="viewport"
+		      content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
+		<meta http-equiv="X-UA-Compatible" content="ie=edge">
+		<title>RangLimier - Notes et rang</title>
+		<link rel="stylesheet" href="assets/bootstrap.min.css">
+		<link rel="stylesheet" href="assets/divers.css">
+	</head>
+	<body>
+	<h1>RangLimier - Rang selon note d'un ECN</h1>
+		<p>Cet outil permet, en entrant une note et une année d'ECN, de voir le rang le plus proche associé.<br>
+		<i>Attention : Cet outil est à but purement indicatif !</i>
+		</p>
 	<link rel="stylesheet" href="assets/bootstrap.min.css">
 	<style>
 	/* Tableau */
@@ -227,7 +243,7 @@ EOF;
 		$html .= "</tr>";
 	}
 	
-	$html .= "</tbody></table><br>";
+	$html .= "</tbody></table><br></body>";
 	
 	// Affichage du HTML demandé
 	echo $html;

+ 3 - 2
composer.json

@@ -11,8 +11,9 @@
     "require": {
         "firebase/php-jwt": "^5.2",
 	    "ext-curl": "*",
-        "ext-json": "*"
-    }
+        "ext-json": "*",
+	    "ext-pdo": "*"
+	}
     ,
     "require-dev": {
         "roave/security-advisories": "dev-latest"