summaryrefslogtreecommitdiffstats
path: root/lib/init.php
diff options
context:
space:
mode:
authorKarl 'vollmerk' Vollmer <vollmer@ampache.org>2006-11-12 20:10:22 +0000
committerKarl 'vollmerk' Vollmer <vollmer@ampache.org>2006-11-12 20:10:22 +0000
commit85a3474424ec5ea06be2f0f27198c9ba7f739af9 (patch)
tree6c33ccb31e1baff46c83ccbe393382e55c5cbcb6 /lib/init.php
parent229ae80fc9b3ae7157ff216330575efae5ec80b5 (diff)
downloadampache-85a3474424ec5ea06be2f0f27198c9ba7f739af9.tar.gz
ampache-85a3474424ec5ea06be2f0f27198c9ba7f739af9.tar.bz2
ampache-85a3474424ec5ea06be2f0f27198c9ba7f739af9.zip
added ability to vote songs up and down in democratic play and fixed a problem with ajax not resetting the gettext() and not having a user or session
Diffstat (limited to 'lib/init.php')
-rw-r--r--lib/init.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/init.php b/lib/init.php
index 47c55ad3..b6826943 100644
--- a/lib/init.php
+++ b/lib/init.php
@@ -289,7 +289,13 @@ elseif (!conf('use_auth')) {
set_theme();
}
else {
- $user = new user();
+ if (isset($_REQUEST['sessid'])) {
+ $results = vauth_get_session($_REQUEST['sessid']);
+ session_id(scrub_in($_REQUEST['sessid']));
+ session_start();
+ }
+ $user = new user($results['username']);
+ init_preferences();
}