Commit 32c17a99c3ce6d34bd1ad0eeaeecb2482cad3ebe
1 parent
1ed732a0
Supprimé (tout) ce qui était inutile
Showing
8 changed files
with
4 additions
and
104 deletions
Show diff stats
.gitignore
.htaccess
checkCreds.php deleted
@@ -1,32 +0,0 @@ | @@ -1,32 +0,0 @@ | ||
1 | -<?php | ||
2 | -session_start(); | ||
3 | -require_once("creds.php"); | ||
4 | - | ||
5 | -if(!(isset($_GET["user"])&&isset($_GET["pass"]))) | ||
6 | - die("Nop"); | ||
7 | - | ||
8 | -$link = mysql_connect(__MYSQL_HOSTNAME__, __MYSQL_USERNAME__, __MYSQL_PASSWORD__) | ||
9 | - or die("Nop"); | ||
10 | - | ||
11 | -if(!mysql_select_db('crep', $link)) | ||
12 | - die('Nop'); | ||
13 | -$requete = 'SELECT pk, admin, realname FROM users WHERE username=\''.$_GET["user"].'\' AND password=\''.$_GET["pass"].'\''; | ||
14 | -$resultat = mysql_query($requete); | ||
15 | - | ||
16 | -if (!$resultat) | ||
17 | - die("Nop"); | ||
18 | - | ||
19 | -if($row = mysql_fetch_row($resultat)) | ||
20 | -{ | ||
21 | - echo 'Yep'; | ||
22 | - $_SESSION["connected"]=true; | ||
23 | - $_SESSION["pk"]=$row[0]; | ||
24 | - $_SESSION["admin"]=$row[1]; | ||
25 | - $_SESSION["realname"]=$row[2]; | ||
26 | -} | ||
27 | -else | ||
28 | - echo 'Nop'; | ||
29 | - | ||
30 | - | ||
31 | -mysql_close($link); | ||
32 | -?> |
connect.php deleted
@@ -1,51 +0,0 @@ | @@ -1,51 +0,0 @@ | ||
1 | -<h2> Connexion </h2> | ||
2 | -<form class="form-horizontal" role="form" id="connectForm"> | ||
3 | - <div class="form-group"> | ||
4 | - <label for="entrer_Identifiant_3" class="col-sm-2 control-label">Identifiant</label> | ||
5 | - <div class="col-sm-10"> | ||
6 | - <input type="identifiant" class="form-control" id="Entrer_Identifiant_3" placeholder="Votre identifiant"> | ||
7 | - </div> | ||
8 | - </div> | ||
9 | - <div class="form-group"> | ||
10 | - <label class="col-sm-2 control-label" for="entrer_mot_de_passe_3">Mot de passe</label> | ||
11 | - <div class="col-sm-10"> | ||
12 | - <div class="input-group"> | ||
13 | - <input type="password" class="form-control" id="entrer_mot_de_passe_3" placeholder="Votre mot de passe"> | ||
14 | - <span class="input-group-btn"> | ||
15 | - <button id="afficherMotDePasse" type="button" class="btn btn-default"><span class="glyphicon glyphicon glyphicon-eye-open"></span> Afficher</button> | ||
16 | - </span> | ||
17 | - </div> | ||
18 | - </div> | ||
19 | - </div> | ||
20 | - <div class="form-group"> | ||
21 | - <div class="col-sm-offset-2 col-sm-10"> | ||
22 | - <button id="validCreds" type="submit" class="btn btn-primary">Se connecter</button> | ||
23 | - </div> | ||
24 | - </div> | ||
25 | -</form> | ||
26 | - | ||
27 | -<script type="text/javascript"> | ||
28 | -// Affiche le mot de passe | ||
29 | -$("#afficherMotDePasse")[0].addEventListener('mousedown', function() | ||
30 | -{ | ||
31 | - $('#entrer_mot_de_passe_3')[0].type = 'text'; | ||
32 | -}); | ||
33 | -$('#afficherMotDePasse')[0].addEventListener('mouseup', function() | ||
34 | -{ | ||
35 | - $('#entrer_mot_de_passe_3')[0].type = 'password'; | ||
36 | -}); | ||
37 | -$('#connectForm').submit(function(event) | ||
38 | -{ | ||
39 | - $("#validCreds")[0].disabled=true; | ||
40 | - var checkPath = "checkCreds.php?user="; | ||
41 | - checkPath += $("#Entrer_Identifiant_3")[0].value; | ||
42 | - checkPath += "&pass="; | ||
43 | - checkPath += Whirlpool($("#entrer_mot_de_passe_3")[0].value); | ||
44 | - if(file(checkPath)=="Yep") | ||
45 | - document.location.replace(""); | ||
46 | - else | ||
47 | - alert("Mauvais identifiants"); | ||
48 | - $("#validCreds")[0].disabled=false; | ||
49 | - event.preventDefault(); | ||
50 | -}); | ||
51 | -</script> |
index.php
1 | <?php | 1 | <?php |
2 | 2 | ||
3 | -if ($_SERVER['HTTP_HOST'] == 'crepbeta.plil.net') { | ||
4 | - header('HTTP/1.1 307 Temporary Redirect'); | ||
5 | - header('Location: http://crep.plil.net/'); | ||
6 | - exit(); | ||
7 | -} | ||
8 | - | ||
9 | -session_start(); | ||
10 | - | ||
11 | -require_once("creds.php"); | ||
12 | - | ||
13 | $url = $_SERVER["REQUEST_URI"]; | 3 | $url = $_SERVER["REQUEST_URI"]; |
14 | $parsedUrl = parse_url($url); | 4 | $parsedUrl = parse_url($url); |
15 | $path = $parsedUrl['path']; | 5 | $path = $parsedUrl['path']; |
@@ -52,10 +42,8 @@ if (isset($_GET['c'])) { | @@ -52,10 +42,8 @@ if (isset($_GET['c'])) { | ||
52 | <script type="text/javascript" src="js/jquery.min.js"></script> | 42 | <script type="text/javascript" src="js/jquery.min.js"></script> |
53 | <script type="text/javascript" src="js/bootstrap.min.js"></script> | 43 | <script type="text/javascript" src="js/bootstrap.min.js"></script> |
54 | <script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?v=3.exp"></script> | 44 | <script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?v=3.exp"></script> |
55 | - <!-- <script type="text/javascript" src="js/whirlpool.min.js"></script> --> | ||
56 | <script type="text/javascript" src="js/crep.js"></script> | 45 | <script type="text/javascript" src="js/crep.js"></script> |
57 | <script type="text/javascript" src="js/konami.js"></script> | 46 | <script type="text/javascript" src="js/konami.js"></script> |
58 | - <!-- <script type="text/javascript" src="js/base64.js"></script> --> | ||
59 | </head> | 47 | </head> |
60 | <body> | 48 | <body> |
61 | <?php require_once("topnavbar.php");?> | 49 | <?php require_once("topnavbar.php");?> |
logout.php deleted
pages/schools.php
rights.php deleted