Hey,
Ok, what I need to be able to do is allow people to log-in and register with my site even if they have cookies disabled. At the moment this is not possible.
I'm running sessions and I have read on here about session.use_trans_sid and --enable-trans-sid.
Now, my host is running PHP 4.0.6, it will soon be upgraded to PHP 4.1.2
I can't access the php.ini file but they said I can alter other settings for my local account by using a .htaccess file.
So what I need to know is, how do I go about using the session.use_trans_sid function with --enabled-trans-sid??
You are all talking about doing it in the php.ini file but I can't access this so any ideas?
Here is the code for sessions on my site:
<?php
include("access/data.inc.php");
if ($variables!="")
{
$variables = base64_decode ($variables);
$data = explode ("||",$variables);
$userid = $data[0];
$password = $data[1];
}
mysql_connect ($SQLhost, $SQLuser, $SQLpass);
mysql_select_db ($SQLdb);
$res_access = mysql_query ("SELECT id, userid, registered, name FROM users where userid='$userid' and password='$password' and registered='1'");
$num_access = mysql_num_rows ($res_access);
/* user not found */
if ($num_access == 0)
{
header("Location: $VARredirect");
exit;
}
/* user found, opening session */
session_save_path('/home/dir/accessdata');
session_start();
session_register('access_id');
session_register('access_userid');
session_register('access_name');
$access_id = mysql_result ($res_access,0,"id");
$access_userid = mysql_result ($res_access,0,"userid");
$access_name = mysql_result ($res_access,0,"name");
$access_name = strtolower ($access_name);
$access_name = ucwords ($access_name);
header("Location: $VARpass");
exit;
?>
Any ideas guys?
Cheers,
Chris