diff options
-rwxr-xr-x | docs/CHANGELOG | 4 | ||||
-rw-r--r-- | lib/class/update.class.php | 30 | ||||
-rw-r--r-- | lib/init.php | 6 |
3 files changed, 35 insertions, 5 deletions
diff --git a/docs/CHANGELOG b/docs/CHANGELOG index 4ad067ae..c75b4259 100755 --- a/docs/CHANGELOG +++ b/docs/CHANGELOG @@ -4,7 +4,9 @@ -------------------------------------------------------------------------- v.3.3.3-Beta2 12/18/2006: - - Fixed a bug that prevented adding new songs to the catalog + - Fixed a bug that prevented adding new songs to the catalog. + - Removed a upload preference that I missed. + - Timezone setting actually works -------------------------------------------------------------------------- diff --git a/lib/class/update.class.php b/lib/class/update.class.php index 9db77f45..9dd0d5a7 100644 --- a/lib/class/update.class.php +++ b/lib/class/update.class.php @@ -331,11 +331,15 @@ class Update { $update_string = '- Added object_tag table for Web2.0 style tag information.<br />' . '- Added song_ext_data for holding comments,lyrics and other large fields, not commonly used.<br />' . - '- Added Timezone as a per user preference.<br />' . + '- Added Timezone as a site preference.<br />' . '- Delete Upload Table and Upload Preferences.<br />'; $version[] = array('version' => '333002','description' => $update_string); + $update_string = '- Removed Last Upload Preference'; + + $version[] = array('version' => '333003','description' => $update_string); + return $version; } // populate_version @@ -2111,5 +2115,29 @@ class Update { } // update_333002 + /** + * update_333003 + * This update removes the last upload preference + */ + function update_333003() { + + $sql = "DELETE FROM preferences WHERE `name`='quarantine'"; + $db_results = mysql_query($sql,dbh()); + + /* Fix every users preferences */ + $sql = "SELECT * FROM user"; + $db_results = mysql_query($sql,dbh()); + + $user = new User(); + $user->fix_preferences('-1'); + + while ($r = mysql_fetch_assoc($db_results)) { + $user->fix_preferences($r['username']); + } // while results + + $this->set_version('db_version','333003'); + + } // update_333003 + } // end update class ?> diff --git a/lib/init.php b/lib/init.php index ecb8c2c5..7b834c75 100644 --- a/lib/init.php +++ b/lib/init.php @@ -229,9 +229,6 @@ if (($gc_divisor / $gc_probability) > 5) { ini_set('session.gc_probability',$new_gc_probability); } -/* PHP5 Date problem solved.. ya'll GMT now! */ -putenv("TZ=GMT"); - /* Seed the random number */ srand((double) microtime() * 1000003); @@ -306,6 +303,9 @@ else { init_preferences(); } +/* PHP5 Date problem solved.. ya'll GMT now! */ +$timezone = "TZ=" . conf('time_zone'); +putenv($timezone); /* Add in some variables for ajax done here because we need the user */ $ajax_info['ajax_url'] = $results['web_path'] . '/server/ajax.server.php'; |