forked from rebillar/site-accueil-insa
fixed inclusion error and added help at index
This commit is contained in:
parent
16d0f61d75
commit
cebdfc4490
3 changed files with 16 additions and 4 deletions
|
@ -4,6 +4,8 @@ include "script.php";
|
|||
//CAS
|
||||
require_once("../phpCAS-1.3.6/CAS.php");
|
||||
|
||||
$_SESSION['id']=1;
|
||||
/*
|
||||
// Initialize phpCAS
|
||||
phpCAS::client(CAS_VERSION_2_0, "cas.insa-toulouse.fr", 443, 'cas', true);
|
||||
|
||||
|
@ -17,7 +19,7 @@ phpCAS::forceAuthentication();
|
|||
|
||||
// at this step, the user has been authenticated by the CAS server
|
||||
// and the user's login name can be read with phpCAS::getUser().
|
||||
$pseudo = phpCAS::getUser();
|
||||
$pseudo = phpCAS::getUser();*/
|
||||
|
||||
if(!isset($_SESSION['id'])) {
|
||||
$req = $db->prepare("SELECT id FROM admin WHERE pseudo = ?");
|
||||
|
@ -39,6 +41,7 @@ if(isset($_POST['login'])) {
|
|||
session_destroy();
|
||||
header('Refresh:0');
|
||||
}
|
||||
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
@ -67,6 +70,7 @@ if(isset($_POST['login'])) {
|
|||
echo "<font color='red'>Admin</font>";
|
||||
break;
|
||||
}
|
||||
echo "<br> Si l'onglet que vous recherchez n'est pas disponible, demandez avec amour et volupté une élévation d'acces à un respo web.";
|
||||
} else {
|
||||
?>
|
||||
<form method="POST">
|
||||
|
|
|
@ -78,7 +78,14 @@ if(isset($_POST['send'])) {
|
|||
|
||||
header('Refresh: 0');
|
||||
} else {
|
||||
if(isset($_POST['day']) AND !empty($_POST['day']) AND isset($_POST['title']) AND !empty($_POST['title']) AND isset($_POST['description']) AND !empty($_POST['description']) AND isset($_POST['color']) AND !empty($_POST['color']) AND isset($_POST['order_start']) AND !empty($_POST['order_start']) AND isset($_POST['length']) AND !empty($_POST['length']) AND isset($_POST['num_planning']) AND !empty($_POST['num_planning']) AND isset($_POST['opacity'])) {
|
||||
if(isset($_POST['day']) AND !empty($_POST['day'])
|
||||
AND isset($_POST['title']) AND !empty($_POST['title'])
|
||||
AND isset($_POST['description']) AND !empty($_POST['description'])
|
||||
AND isset($_POST['color']) AND !empty($_POST['color'])
|
||||
AND isset($_POST['order_start']) AND !empty($_POST['order_start'])
|
||||
AND isset($_POST['length']) AND !empty($_POST['length'])
|
||||
AND isset($_POST['num_planning']) AND !empty($_POST['num_planning'])
|
||||
AND isset($_POST['opacity'])) {
|
||||
|
||||
$day = (int) htmlspecialchars($_POST['day']);
|
||||
$title = htmlspecialchars($_POST['title']);
|
||||
|
@ -222,4 +229,5 @@ if(isset($_POST['send'])) {
|
|||
</table>
|
||||
</main>
|
||||
</body>
|
||||
|
||||
</html>
|
|
@ -1,7 +1,7 @@
|
|||
<?php
|
||||
include "script.php";
|
||||
|
||||
include "assets/scripts/globals.php"
|
||||
include "../assets/scripts/globals.php";
|
||||
|
||||
$req = $db->query('SELECT id, texte, points, team, id_staff FROM scores');
|
||||
|
||||
|
@ -89,7 +89,7 @@ if(isset($_POST['send'])) {
|
|||
<form method="POST">
|
||||
<input type="submit" name="teamall" value="All" class="submit_inline">
|
||||
<input type="submit" name="team0" value="<?=$TEAM1?>" class="submit_inline">
|
||||
<input type="submit" name="team1" value="<?=$TEAM1?>" class="submit_inline">
|
||||
<input type="submit" name="team1" value="<?=$TEAM2?>" class="submit_inline">
|
||||
</form>
|
||||
<br><br>
|
||||
<table class="acces">
|
||||
|
|
Loading…
Reference in a new issue