So let me get this straight, If the login system is working, and the variables are being set, then The Control Panel must be the problem. Paste that code here, andd maybe the is somthing worng there.![]()
So let me get this straight, If the login system is working, and the variables are being set, then The Control Panel must be the problem. Paste that code here, andd maybe the is somthing worng there.![]()
-Ben -- THE DYNAMIC DRIVERS
My Links: My DD Profile||My Youtube Video Tutorials||DD Helping Coders||DD Coders In Training
I told my client to press F5, the client pressed F, then 5, *facepalm*
Here's what is at the top of Control Panel:
$_SESSION['logged'] is defined when logged in, if the value is less than 1 (e.g. 0) it will redirect the user back to the sign in page.Code:<?php session_start(); if($_SESSION['logged'] == 1){ include 'd/user.connect.inc.php'; ?>
Here's what is at the bottom of the page:
Then that's about it really, the rest is just echoing the $_SESSION data that was set previously when the user logged in.Code:<?php } else { header("Location: signin/index.phtml"); } ?>
I hope this helps, if you need anymore of my script to work out this problem then just ask.
I'm currently doing a few adjustments to the code, to see if that will fix this problem but still no luck yet.
You have WAY too may "logged in" variables:
if(isset($_SESSION['uid'])){ and
if($_SESSION['logged'] == 1){ and
if($_SESSION["s_username"]){
they all check the same thing, whether the user is logged in.
Stick with 1 variable, the "logged" one, and change these (blue)
and change this (on the login page):Code:<?php session_start(); if(!$_SESSION['logged'] == 1){ include 'd/user.connect.inc.php'; ?> html stuff --- <p><b>Notice:</b> You are already logged in as <b><?php echo $_SESSION['s_username']; ?></b>... Please go to your <a href="http://users.domain.com/cp.php">Control Panel</a></p> --- More html stuff (if logged in) <?php } else { echo 'Not Logged in...'; ?> More stuff to show if not logged in <?php } ?> other html ending html stuff (both)
Hope this helps!Code:if($row['activated'] > 0) //checks to see if the user is activated or not. { $_SESSION['logged'] = '1';
-Ben -- THE DYNAMIC DRIVERS
My Links: My DD Profile||My Youtube Video Tutorials||DD Helping Coders||DD Coders In Training
I told my client to press F5, the client pressed F, then 5, *facepalm*
Bookmarks