From a2aa86161d6d0ecd116410642e738ce5183a8e18 Mon Sep 17 00:00:00 2001 From: Divlo Date: Fri, 23 Aug 2019 11:36:13 +0200 Subject: [PATCH] Optimisation du header/menu --- incl/header.php | 20 +++++++++++++++++++- incl/menu.php | 18 ------------------ index.php | 20 -------------------- php/headPerso.php | 5 +++++ views/404.php | 3 --- views/error404.php | 3 --- views/function-list.php | 20 -------------------- views/function-views/calculateAge.php | 3 --- views/function-views/convertDistance.php | 3 --- views/function-views/convertTemperature.php | 3 --- views/function-views/randomNumber.php | 3 --- views/function-views/weatherRequest.php | 3 --- 12 files changed, 24 insertions(+), 80 deletions(-) delete mode 100644 incl/menu.php diff --git a/incl/header.php b/incl/header.php index 83f47f4..e1a94d4 100644 --- a/incl/header.php +++ b/incl/header.php @@ -55,4 +55,22 @@ - + + \ No newline at end of file diff --git a/incl/menu.php b/incl/menu.php deleted file mode 100644 index 646de5b..0000000 --- a/incl/menu.php +++ /dev/null @@ -1,18 +0,0 @@ - - - - - \ No newline at end of file diff --git a/index.php b/index.php index 2886fee..9fce41b 100644 --- a/index.php +++ b/index.php @@ -4,26 +4,6 @@ - - - - - - -

Bienvenue sur FunctionProject! 🎉

diff --git a/php/headPerso.php b/php/headPerso.php index f441639..56cbc93 100644 --- a/php/headPerso.php +++ b/php/headPerso.php @@ -2,16 +2,21 @@ $currentpage = $_SERVER['PHP_SELF']; +$indexActive = ''; +$functionlistActive = ''; + switch ($currentpage) { case '/index.php': $title = 'FunctionProject'; $description = 'FunctionProject est un projet créé par Divlo qui a pour but de rassembler plein de mini-programme (fonctions JavaScript) permettant de faire plusieurs choses comme savoir la météo, générer un nombre aléatoire, etc.'; $image = 'https://function.divlo.fr/img/FunctionProject_icon.png'; + $indexActive = 'active'; break; case '/views/function-list.php': $title = 'Liste des fonctions'; $description = 'La liste des mini-programmes (fonctions JavaScript).'; $image = 'https://function.divlo.fr/img/FunctionProject_icon.png'; + $functionlistActive = 'active'; break; case '/views/function-views/calculateAge.php': $title = 'Quelle âge avez-vous ?'; diff --git a/views/404.php b/views/404.php index a53a6bf..6016727 100644 --- a/views/404.php +++ b/views/404.php @@ -4,9 +4,6 @@ - - -

Erreur 404

diff --git a/views/error404.php b/views/error404.php index 96f958c..e1b2515 100644 --- a/views/error404.php +++ b/views/error404.php @@ -4,9 +4,6 @@ - - -

La météo :

diff --git a/views/function-list.php b/views/function-list.php index 37661fa..4ce6892 100644 --- a/views/function-list.php +++ b/views/function-list.php @@ -4,26 +4,6 @@ - - -
-
- - -
diff --git a/views/function-views/calculateAge.php b/views/function-views/calculateAge.php index 436e92e..5ff9dc7 100644 --- a/views/function-views/calculateAge.php +++ b/views/function-views/calculateAge.php @@ -4,9 +4,6 @@ - - -

diff --git a/views/function-views/convertDistance.php b/views/function-views/convertDistance.php index 440a002..0fd0d8b 100644 --- a/views/function-views/convertDistance.php +++ b/views/function-views/convertDistance.php @@ -4,9 +4,6 @@ - - -

:

diff --git a/views/function-views/convertTemperature.php b/views/function-views/convertTemperature.php index f71566e..41d0549 100644 --- a/views/function-views/convertTemperature.php +++ b/views/function-views/convertTemperature.php @@ -4,9 +4,6 @@ - - -

:

diff --git a/views/function-views/randomNumber.php b/views/function-views/randomNumber.php index 825188c..7bad91c 100644 --- a/views/function-views/randomNumber.php +++ b/views/function-views/randomNumber.php @@ -4,9 +4,6 @@ - - -

:

diff --git a/views/function-views/weatherRequest.php b/views/function-views/weatherRequest.php index 9c894ed..ae41526 100644 --- a/views/function-views/weatherRequest.php +++ b/views/function-views/weatherRequest.php @@ -4,9 +4,6 @@ - - -

: