I am in hopes that the php Gods can help me out here...this is a
bit longwinded, as I am trying to get all the info here to display
all that is going on 🙂
In a nutshell, I have a frame site (header, nav on the left, and
main frame for the content). I have a button in the nav for a
'members' area. When a user clicks it, they are sent to an html
page that has a link to 'log in'. Using the .htaccess, they then
imput the un/pw and are redirected to their area that has been
set up. The redirection script is as follows...
<?php
function REDIRECT(){
global $REMOTE_USER;
switch (strtoupper($REMOTE_USER)) {
case "USR1": { Header("Location: users/usr1/index.html"); break;}
case "USR2": { Header("Location: users/usr2/index.html"); break;}
default: {Header("Location: access_denied.html"); }
}}
REDIRECT();
?>
Please bear in mind that the user's page that they are redirected
to loads in the main frame. Does anyone have/know where I can
get some code that will generate a session? I assume a cookie
will do it, but I am not that much of a programmer and this is
driving me nuts!
When I log in as me, and I click a few other buttons in my nav,
then click the 'members' button again, I am automatically sent
to the page that I want protected. Basically, what I want to do
is have it set up so that when a user is 'logged in', the session
will only last say 15 mins. Is there any way that I can do this?
I would love to log in, then click the log in button in the nav and
if I go to log into the members area again, be prompted w/ the
lil pop up window that asks for a un/pw like it did upon a fresh
viewing of the page.
I hope this makes some sort of sence...the machine is Unix if that
helps...Please help me...you guys rock!
Carl