PHP Classes

File: testaccess.php

Recommend this page to a friend!
  Classes of zinsou A.A.E.Moïse   tinyUGatMs   testaccess.php   Download  
File: testaccess.php
Role: Example script
Content type: text/plain
Description: test script
Class: tinyUGatMs
Manage users and groups of events in a database
Author: By
Last change:
Date: 6 years ago
Size: 1,843 bytes
 

Contents

Class file image Download
<?php
session_start
();
require_once(
'usefullfunctions.php');
$url='connexion.php';
?>
<!DOCTYPE>
    <html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <title>GROUP ACCESS TIME</title>

    <style type="text/css">
       
         #other {
            font-family: verdana;
            font-weight: bold;
            font-size: 14px;
            font-style:italic;
            color: #FFFFFF;
            background-color: grey;
            width: auto;
            margin-left: 15%;
            margin-right: 15%;
            padding:2%;
        }
       
        label
        {
            display: block ;
            width: 150px;
            float : left ;
        }
        </style>
   
    </head>
<body>
<div id="other">
<?php
if(isset($_SESSION ['groupstatut'])&&isset($_SESSION["startaccesstime"])&&isset($_SESSION["endaccesstime"])&&$_SESSION ['groupstatut']==true&&inrangetime(explode(':',date('H:I:s')),explode(':',$_SESSION["startaccesstime"]),explode(':',$_SESSION["endaccesstime"]))){
if(isset(
$_SESSION['role'])&&$_SESSION['role']=="admin"){
    echo
'<div><p>welcome buddy <a href="./logout.php">logout</a><br>Here is your future cool and fresh member area</p>
    <p>What do you want to do ?
            <ul><li><a href="./managegroups.php?action=edit">Edit existing groups ?</a></li>
            <li><a href="./managegroups.php?action=add">Add a new group ?</a></li>
            <li><a href="./managegroups.php?action=delete">DELETE a group ?</a></li>
            <li><a href="./manageusers.php?action=edit">Edit existing user ?</a></li>
            <li><a href="./manageusers.php?action=add">Add a new user ?</a></li>
            <li><a href="./manageusers.php?action=delete">DELETE a user ?</a></li></ul>
            </p></div>'
;
}else{
echo
'welcome buddy <a href="./logout.php">logout</a><br>Here is your future cool and fresh member area';
}

}else{
echo
'<script type="text/javascript">window.location="'.$url.'";</script>';
exit;
}
?>
</div>
</body>
</html>