From 1b35c20dd0a93b143d8b9542743a743e0db66386 Mon Sep 17 00:00:00 2001 From: martian Date: Tue, 9 Feb 2010 17:44:44 +0000 Subject: Adding the bandwidth option to the preferences. This changes the complexity of the UI and toggles album art. --- lib/class/user.class.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lib/class/user.class.php') diff --git a/lib/class/user.class.php b/lib/class/user.class.php index 5608e025..40065922 100644 --- a/lib/class/user.class.php +++ b/lib/class/user.class.php @@ -197,7 +197,8 @@ class User extends database_object { $sql = "SELECT preference.name, preference.description, preference.catagory, preference.level, user_preference.value " . "FROM preference INNER JOIN user_preference ON user_preference.preference=preference.id " . - "WHERE user_preference.user='$user_id' " . $user_limit; + "WHERE user_preference.user='$user_id' " . $user_limit . " ORDER BY preference.catagory, preference.description"; + $db_results = Dba::read($sql); /* Ok this is crapy, need to clean this up or improve the code FIXME */ @@ -206,7 +207,7 @@ class User extends database_object { $admin = false; if ($type == 'system') { $admin = true; } $type_array[$type][$r['name']] = array('name'=>$r['name'],'level'=>$r['level'],'description'=>$r['description'],'value'=>$r['value']); - ksort($type_array[$type]); + //ksort($type_array[$type]); // sorted this via sql and added sub-category sorting - Vlet $results[$type] = array ('title'=>ucwords($type),'admin'=>$admin,'prefs'=>$type_array[$type]); } // end while -- cgit