aboutsummaryrefslogtreecommitdiffstats
path: root/include/user.inc.php
diff options
context:
space:
mode:
authorrvelices <rv-github@modusoptimus.com>2006-04-21 02:11:29 +0000
committerrvelices <rv-github@modusoptimus.com>2006-04-21 02:11:29 +0000
commit4d73790a1b6194c024f4cc159311b260349df6a0 (patch)
tree833f62fe236067cf4bd9620aa2d68065b88a546b /include/user.inc.php
parentc000b9ed60d13c1a40df39f4d5f16bbd5bfd92b0 (diff)
merge r1230 from branch-1_6 into trunk
bugs 344 and 308: broken user id in $_SESSION due to php.ini register_globals git-svn-id: http://piwigo.org/svn/trunk@1231 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'include/user.inc.php')
-rw-r--r--include/user.inc.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/include/user.inc.php b/include/user.inc.php
index 83d86a6c7..47b318eeb 100644
--- a/include/user.inc.php
+++ b/include/user.inc.php
@@ -26,22 +26,22 @@
// +-----------------------------------------------------------------------+
// retrieving connected user informations
-if (isset($_COOKIE[session_name()]))
+if (isset($_COOKIE[session_name()]))
{
session_start();
- if (isset($_SESSION['id']))
+ if (isset($_SESSION['pwg_uid']))
{
- $user['id'] = $_SESSION['id'];
+ $user['id'] = $_SESSION['pwg_uid'];
$user['is_the_guest'] = false;
}
- else
+ else
{
// session timeout
$user['id'] = $conf['guest_id'];
$user['is_the_guest'] = true;
}
-}
-else
+}
+else
{
$user['id'] = $conf['guest_id'];
$user['is_the_guest'] = true;
@@ -55,7 +55,7 @@ if ($conf['apache_authentication'] and isset($_SERVER['REMOTE_USER']))
register_user($_SERVER['REMOTE_USER'], '', '');
$user['id'] = get_userid($_SERVER['REMOTE_USER']);
}
-
+
$user['is_the_guest'] = false;
}
$user = array_merge(