From 6f916e49d5b431c2c1961a13d1a61fef8c02d628 Mon Sep 17 00:00:00 2001 From: Andy Lindeman Date: Fri, 22 Apr 2011 18:15:17 -0400 Subject: Allow timezone to be configurable * Fixes #1637 * New advanced setting gallery/timezone * Default setting comes from PHP --- modules/gallery/helpers/gallery_installer.php | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'modules/gallery/helpers') diff --git a/modules/gallery/helpers/gallery_installer.php b/modules/gallery/helpers/gallery_installer.php index 20de1fea..2cb04356 100644 --- a/modules/gallery/helpers/gallery_installer.php +++ b/modules/gallery/helpers/gallery_installer.php @@ -683,6 +683,13 @@ class gallery_installer { module::set_var("gallery", "apple_touch_icon_url", "lib/images/apple-touch-icon.png"); module::set_version("gallery", $version = 47); } + + if ($version == 47) { + // Add configuration variable to set timezone. Defaults to the currently + // used timezone (from PHP configuration). + module::set_var("gallery", "timezone", Kohana::config('locale.timezone')); + module::set_version("gallery", $version = 48); + } } static function uninstall() { -- cgit v1.2.3