Hi!
I'm getting these warnings:
Warning: session_start() [function.session-start]: Node no longer exists in (file) on line 2
Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at file:2) in file on line 2
Warning: Unknown: Node no longer exists in Unknown on line 0
I have a xml file. Php takes some information from this file, and it saves it in $_SESSION. But something's wrong. What?
function convert($text){
//some code
}
$username=$_POST['user_name'];
$password=$_POST['password'];
$password=md5($password);
$cood=$_POST['cood'];
include("sigurnost/securimage.php");
$img=new Securimage();
$valid=$img->check($cood);
if($valid==true){
$xml=new SimpleXMLElement('database/data.xml',null,true);
foreach($xml as $data){
if($data->userName==$username && $data->password==$password){
session_start();
$_SESSION['name']=convert($data->name);
$_SESSION['cognomen']=convert($data->forname);
$_SESSION['username']=convert($data->userName);
$_SESSION['id']=$data->id;
$_SESSION['password']=$data->password;
$_SESSION['email']=convert($data->email);
session_register("user_Name");
header("location:ok.php");
}
}
}else $error="1";