ztec / adLDAP

adLDAP
GNU Lesser General Public License v2.1
7 stars 6 forks source link

add a login requirement to the example menu.php? #6

Closed lachlan-00 closed 10 years ago

lachlan-00 commented 10 years ago

hi, i just really wanted to say i was how impressed with how easy this was to set up. I spent more time configuring apache and writing site code than configuring this. :)

I was just wondering if it would help in the examples to have session requirements inside the menu.php files?

eg: <?php session_start(); $username = $_SESSION['username']; // or whatever you called it if (!($username)) { $redir = "Location: http://" . $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . "authenticate.php"; header($redir); } ?>

maybe that's obvious to regular web developers but it night helps those like me who program other things. but it would be a great way of testing once the initial config in adldap.php was completed.

ztec commented 10 years ago

You should post this issue to the official Github repository of adldap : https://github.com/adldap/adldap/issues

This one will be shuted down one day. The official is now up and running and my fork is not mandatory.