session_start(); HELP!
Posted: Fri Aug 04, 2006 4:36 am
feyd | Please use
and i include this code on top of every page i use....it works well....
though...i have a slight problem...
i open a PopUp window with JavaScript and in this window i have alsow included this code and in mozilla works fine though in IE sends me on login screen..
Can anyone explain this to me?
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
i need some help here guys...
i have a code like this...Code: Select all
<?php session_start();
include_once'settings.php';
$username = $_POST['username'];
if (file_exists("$users/$username.php"))
{
$user = file_get_contents("$users/$username.php");
$user_name = explode ("=", $user);
$pass_is = $user_name[1];
$password = $_POST['password'];
if ($pass_is == $password){
$_SESSION['is_logged']=1;
setcookie("Test", $username, time()+3600, "/","this.com"); /* expire in 1 hour */
} else {
$_SESSION['is_logged']=0;
}
}
if(!$_SESSION['is_logged']){
header("location: logon.php");
}
?>though...i have a slight problem...
i open a PopUp window with JavaScript and in this window i have alsow included this code and in mozilla works fine though in IE sends me on login screen..
Can anyone explain this to me?
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]