Passed
Push — master ( e0b597...f1cdd9 )
by Anthony
02:43
created
core/admin/navigation/AdminNavigation.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -5,20 +5,20 @@
 block discarded – undo
5 5
 	use core\HTML\flashmessage\FlashMessage;
6 6
 	use core\Navigation;
7 7
 
8
-	class AdminNavigation extends Navigation{
8
+	class AdminNavigation extends Navigation {
9 9
 
10 10
 		public function setOrdreNavigation($nav) {
11 11
 			$dbc = App::getDb();
12 12
 			$count_nav = count($nav);
13 13
 
14
-			for ($i=0 ; $i<$count_nav ; $i++) {
14
+			for ($i = 0; $i < $count_nav; $i++) {
15 15
 				$lien = explode(".", $nav[$i]);
16 16
 
17 17
 				if ($lien[1] == "page") {
18
-					$dbc->update("ordre", $i+1)->from("navigation")->where("ID_page", "=", $lien[0])->set();
18
+					$dbc->update("ordre", $i + 1)->from("navigation")->where("ID_page", "=", $lien[0])->set();
19 19
 				}
20 20
 				else {
21
-					$dbc->update("ordre", $i+1)->from("navigation")->where("ID_module", "=", $lien[0])->set();
21
+					$dbc->update("ordre", $i + 1)->from("navigation")->where("ID_module", "=", $lien[0])->set();
22 22
 				}
23 23
 			}
24 24
 
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@
 block discarded – undo
5 5
 	use core\HTML\flashmessage\FlashMessage;
6 6
 	use core\Navigation;
7 7
 
8
-	class AdminNavigation extends Navigation{
8
+	class AdminNavigation extends Navigation {
9 9
 
10 10
 		public function setOrdreNavigation($nav) {
11 11
 			$dbc = App::getDb();
Please login to merge, or discard this patch.
core/HTML/flashmessage/FlashMessage.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@
 block discarded – undo
44 44
 					//definit le chemin sachant que l'on part de index.php
45 45
 					$chemin = str_replace("\\", "/", str_replace("index.php", "", $_SERVER['SCRIPT_NAME']).__NAMESPACE__."/view/");
46 46
 				}
47
-				else if  (strstr($_SERVER['SCRIPT_NAME'], "installation.php")) {
47
+				else if (strstr($_SERVER['SCRIPT_NAME'], "installation.php")) {
48 48
 					//definit le chemin sachant que l'on part de admin.php
49 49
 					$chemin = str_replace("\\", "/", str_replace("installation.php", "", $_SERVER['SCRIPT_NAME']).__NAMESPACE__."/view/");
50 50
 				}
Please login to merge, or discard this patch.
core/admin/contenus/ParentTexte.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,9 @@
 block discarded – undo
16 16
 			$query = $dbc->select("titre")->from("page")->where("ID_page", "=", $parent)->get();
17 17
 
18 18
 			if ((is_array($query)) && (count($query) > 0)) {
19
-				foreach ($query as $obj) $this->parent_texte = $obj->titre;
19
+				foreach ($query as $obj) {
20
+					$this->parent_texte = $obj->titre;
21
+				}
20 22
 			}
21 23
 
22 24
 			return $this->parent_texte;
Please login to merge, or discard this patch.
core/admin/contenus/GestionContenus.php 2 patches
Doc Comments   +9 added lines, -6 removed lines patch added patch discarded remove patch
@@ -33,6 +33,9 @@  discard block
 block discarded – undo
33 33
 			return $bloc_editable;
34 34
 		}
35 35
 
36
+		/**
37
+		 * @param integer $parent
38
+		 */
36 39
 		private function getOrdrePage($parent) {
37 40
 			if (($parent != "") || ($parent != 0)) {
38 41
 				$dbc = \core\App::getDb();
@@ -66,13 +69,13 @@  discard block
 block discarded – undo
66 69
 		}
67 70
 
68 71
 		/**
69
-		 * @param $nom_table
70
-		 * @param $nom_id_table
71
-		 * @param $champ
72
+		 * @param string $nom_table
73
+		 * @param string $nom_id_table
74
+		 * @param string $champ
72 75
 		 * @param $value
73
-		 * @param $limit_char
74
-		 * @param $err_char
75
-		 * @param $err_egalite
76
+		 * @param integer $limit_char
77
+		 * @param string $err_char
78
+		 * @param string $err_egalite
76 79
 		 * @param null $value_id_table
77 80
 		 * @return string
78 81
 		 * fonction qui permet de vérifier qu'il n'y ait pas d'erreur dans le champ spécifié ni de doublons
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -60,7 +60,9 @@
 block discarded – undo
60 60
 		private function getParentId($parent) {
61 61
 			$dbc = \core\App::getDb();
62 62
 
63
-			if ($parent == "") return 0;
63
+			if ($parent == "") {
64
+				return 0;
65
+			}
64 66
 
65 67
 			$query = $dbc->select("ID_page")->from("page")->where("titre", " LIKE ", '"%'.$parent.'%"', "", true)->get();
66 68
 
Please login to merge, or discard this patch.
installation/controller/InstallRibs.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -1,6 +1,5 @@
 block discarded – undo
1 1
 <?php
2 2
 	namespace installation\controller;
3
-	use core\functions\ChaineCaractere;
4 3
 	use core\HTML\flashmessage\FlashMessage;
5 4
 	use core\iniparser\IniParser;
6 5
 
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -28,8 +28,7 @@
 block discarded – undo
28 28
 				$this->dbc = new \PDO($this->db_type.':host='.$this->db_host.';dbname='.$this->db_name, $this->db_user, $this->db_pass);
29 29
 
30 30
 				$this->setinstallbdd();
31
-			}
32
-			catch (\PDOException $e) {
31
+			} catch (\PDOException $e) {
33 32
 				//on tente de créer la bdd
34 33
 				$erreur = "getErreur".$e->getCode();
35 34
 				$this->$erreur();
Please login to merge, or discard this patch.
admin/controller/ckeditor.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,5 +2,5 @@
 block discarded – undo
2 2
 	include_once(ROOT.'libs/ckeditor/ckeditor.php');
3 3
 	require_once(ROOT.'libs/ckfinder/ckfinder.php');
4 4
 	$ckeditor = new CKEditor();
5
-	$ckeditor->basePath	= WEBROOT.'libs/ckeditor/';
5
+	$ckeditor->basePath = WEBROOT.'libs/ckeditor/';
6 6
 	CKFinder::SetupCKEditor($ckeditor, WEBROOT.'libs/ckfinder/');
7 7
\ No newline at end of file
Please login to merge, or discard this patch.
core/admin/contenus/gestion/contenus_inline.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@
 block discarded – undo
2 2
 	$gestion_contenu = new \core\admin\contenus\GestionContenus();
3 3
 	$droit_acces = new \core\admin\droitsacces\DroitAcces();
4 4
 
5
-	if ((($droit_acces->getDroitAccesContenu("GESTION CONTENU PAGE", $_POST['id_page']) == true) &&  ($droit_acces->getModifContenu() != 0)) || ($droit_acces->getSuperAdmin() == 1)) {
5
+	if ((($droit_acces->getDroitAccesContenu("GESTION CONTENU PAGE", $_POST['id_page']) == true) && ($droit_acces->getModifContenu() != 0)) || ($droit_acces->getSuperAdmin() == 1)) {
6 6
 
7 7
 		$gestion_contenu->setModifierContenu($_POST['id_page'], $_POST['contenu']);
8 8
 
Please login to merge, or discard this patch.
core/Configuration.php 3 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
 			return $this->cache;
71 71
 		}
72 72
 		public function getDesactiverNavigation(){
73
-		    return $this->desactiver_navigation;
73
+			return $this->desactiver_navigation;
74 74
 		}
75 75
 
76 76
 		//pour la configuration des comptes
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -69,7 +69,7 @@
 block discarded – undo
69 69
 		public function getCache() {
70 70
 			return $this->cache;
71 71
 		}
72
-		public function getDesactiverNavigation(){
72
+		public function getDesactiverNavigation() {
73 73
 		    return $this->desactiver_navigation;
74 74
 		}
75 75
 
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
 		public function getCache() {
54 54
 			return $this->cache;
55 55
 		}
56
-		public function getDesactiverNavigation(){
56
+		public function getDesactiverNavigation() {
57 57
 		    return $this->desactiver_navigation;
58 58
 		}
59 59
 
Please login to merge, or discard this patch.
admin/views/gestion-contenus/inline.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -31,13 +31,13 @@
 block discarded – undo
31 31
 <script>
32 32
 	CKEDITOR.disableAutoInline = true;
33 33
 
34
-	<?php for($i=0 ; $i<$bloc_editable ; $i++):?>
34
+	<?php for ($i = 0; $i < $bloc_editable; $i++):?>
35 35
 		$(document).ready(function() {
36 36
 			console.log("editor<?=$i?>");
37 37
 			$("#editor<?=$i?>").attr("contenteditable", true);
38 38
 		})
39 39
 		var editor<?=$i?> = CKEDITOR.inline("editor<?=$i?>", { customConfig: "<?=WEBROOT?>config/config_ckeditor.js" });
40 40
 		CKFinder.setupCKEditor( editor<?=$i?>, "<?=LIBSWEBROOT?>ckfinder/" );
41
-	<?php endfor;?>
41
+	<?php endfor; ?>
42 42
 </script>
43
-<?php require_once(ROOT."admin/views/gestion-contenus/js/inline.php");?>
44 43
\ No newline at end of file
44
+<?php require_once(ROOT."admin/views/gestion-contenus/js/inline.php"); ?>
45 45
\ No newline at end of file
Please login to merge, or discard this patch.