From 388f7ba3105b0e246a184c96c7a3ec39b5d89e6d Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Sat, 27 Jun 2009 21:12:37 -0700 Subject: Updated for module upgrades: gallery 2 -> 3 comment 1 -> 2 --- installer/install.sql | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'installer') diff --git a/installer/install.sql b/installer/install.sql index 91108460..1fe9b866 100755 --- a/installer/install.sql +++ b/installer/install.sql @@ -55,7 +55,7 @@ CREATE TABLE {comments} ( `server_remote_addr` varchar(32) default NULL, `server_remote_host` varchar(64) default NULL, `server_remote_port` varchar(16) default NULL, - `state` char(15) default 'unpublished', + `state` varchar(15) default 'unpublished', `text` text, `updated` int(9) NOT NULL, PRIMARY KEY (`id`) @@ -208,7 +208,7 @@ CREATE TABLE {modules} ( UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8; SET character_set_client = @saved_cs_client; -INSERT INTO {modules} VALUES (1,1,'gallery',2),(2,1,'user',1),(3,1,'comment',1),(4,1,'organize',1),(5,1,'info',1),(6,1,'rss',1),(7,1,'search',1),(8,1,'slideshow',1),(9,1,'tag',1); +INSERT INTO {modules} VALUES (1,1,'gallery',3),(2,1,'user',1),(3,1,'comment',2),(4,1,'organize',1),(5,1,'info',1),(6,1,'rss',1),(7,1,'search',1),(8,1,'slideshow',1),(9,1,'tag',1); DROP TABLE IF EXISTS {outgoing_translations}; SET @saved_cs_client = @@character_set_client; SET character_set_client = utf8; @@ -333,6 +333,6 @@ CREATE TABLE {vars} ( `value` text, PRIMARY KEY (`id`), UNIQUE KEY `module_name` (`module_name`,`name`) -) ENGINE=InnoDB AUTO_INCREMENT=27 DEFAULT CHARSET=utf8; +) ENGINE=InnoDB AUTO_INCREMENT=28 DEFAULT CHARSET=utf8; SET character_set_client = @saved_cs_client; -INSERT INTO {vars} VALUES (1,'gallery','active_site_theme','default'),(2,'gallery','active_admin_theme','admin_default'),(3,'gallery','page_size','9'),(4,'gallery','thumb_size','200'),(5,'gallery','resize_size','640'),(6,'gallery','default_locale','en_US'),(7,'gallery','image_quality','75'),(9,'gallery','blocks_dashboard_sidebar','a:4:{i:2;a:2:{i:0;s:7:\"gallery\";i:1;s:11:\"block_adder\";}i:3;a:2:{i:0;s:7:\"gallery\";i:1;s:5:\"stats\";}i:4;a:2:{i:0;s:7:\"gallery\";i:1;s:13:\"platform_info\";}i:5;a:2:{i:0;s:7:\"gallery\";i:1;s:12:\"project_news\";}}'),(14,'gallery','blocks_dashboard_center','a:4:{i:6;a:2:{i:0;s:7:\"gallery\";i:1;s:7:\"welcome\";}i:7;a:2:{i:0;s:7:\"gallery\";i:1;s:12:\"photo_stream\";}i:8;a:2:{i:0;s:7:\"gallery\";i:1;s:11:\"log_entries\";}i:9;a:2:{i:0;s:7:\"comment\";i:1;s:15:\"recent_comments\";}}'),(17,'gallery','version','3.0 pre beta 2 (git)'),(18,'gallery','choose_default_tookit','1'),(19,'gallery','date_format','Y-M-d'),(20,'gallery','date_time_format','Y-M-d H:i:s'),(21,'gallery','time_format','H:i:s'),(22,'gallery','credits','Powered by Gallery %version'),(24,'comment','spam_caught','0'); +INSERT INTO {vars} VALUES (1,'gallery','active_site_theme','default'),(2,'gallery','active_admin_theme','admin_default'),(3,'gallery','page_size','9'),(4,'gallery','thumb_size','200'),(5,'gallery','resize_size','640'),(6,'gallery','default_locale','en_US'),(7,'gallery','image_quality','75'),(9,'gallery','blocks_dashboard_sidebar','a:4:{i:2;a:2:{i:0;s:7:\"gallery\";i:1;s:11:\"block_adder\";}i:3;a:2:{i:0;s:7:\"gallery\";i:1;s:5:\"stats\";}i:4;a:2:{i:0;s:7:\"gallery\";i:1;s:13:\"platform_info\";}i:5;a:2:{i:0;s:7:\"gallery\";i:1;s:12:\"project_news\";}}'),(14,'gallery','blocks_dashboard_center','a:4:{i:6;a:2:{i:0;s:7:\"gallery\";i:1;s:7:\"welcome\";}i:7;a:2:{i:0;s:7:\"gallery\";i:1;s:12:\"photo_stream\";}i:8;a:2:{i:0;s:7:\"gallery\";i:1;s:11:\"log_entries\";}i:9;a:2:{i:0;s:7:\"comment\";i:1;s:15:\"recent_comments\";}}'),(17,'gallery','version','3.0 pre beta 2 (git)'),(18,'gallery','choose_default_tookit','1'),(19,'gallery','date_format','Y-M-d'),(20,'gallery','date_time_format','Y-M-d H:i:s'),(21,'gallery','time_format','H:i:s'),(22,'gallery','show_credits','1'),(23,'gallery','credits','Powered by Gallery %version'),(25,'comment','spam_caught','0'); -- cgit v1.2.3 From 5b2c08d797697430dca716cce5b51a4c128027c0 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Sun, 28 Jun 2009 17:37:14 -0700 Subject: Set the gallery module version to 6 in install() (missed this in my last change). Refresh the install.sql. --- installer/install.sql | 15 ++++++++++++++- modules/gallery/helpers/gallery_installer.php | 2 +- 2 files changed, 15 insertions(+), 2 deletions(-) (limited to 'installer') diff --git a/installer/install.sql b/installer/install.sql index 1fe9b866..7da5fe68 100755 --- a/installer/install.sql +++ b/installer/install.sql @@ -32,6 +32,19 @@ CREATE TABLE {access_intents} ( ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8; SET character_set_client = @saved_cs_client; INSERT INTO {access_intents} VALUES (1,1,1,1,0,0,1,1,0,0); +DROP TABLE IF EXISTS {caches}; +SET @saved_cs_client = @@character_set_client; +SET character_set_client = utf8; +CREATE TABLE {caches} ( + `id` int(9) NOT NULL auto_increment, + `key` varchar(255) NOT NULL, + `tags` varchar(255) default NULL, + `expiration` int(9) NOT NULL, + `cache` longblob, + PRIMARY KEY (`id`), + KEY `tags` (`tags`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8; +SET character_set_client = @saved_cs_client; DROP TABLE IF EXISTS {comments}; SET @saved_cs_client = @@character_set_client; SET character_set_client = utf8; @@ -208,7 +221,7 @@ CREATE TABLE {modules} ( UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8; SET character_set_client = @saved_cs_client; -INSERT INTO {modules} VALUES (1,1,'gallery',3),(2,1,'user',1),(3,1,'comment',2),(4,1,'organize',1),(5,1,'info',1),(6,1,'rss',1),(7,1,'search',1),(8,1,'slideshow',1),(9,1,'tag',1); +INSERT INTO {modules} VALUES (1,1,'gallery',6),(2,1,'user',1),(3,1,'comment',2),(4,1,'organize',1),(5,1,'info',1),(6,1,'rss',1),(7,1,'search',1),(8,1,'slideshow',1),(9,1,'tag',1); DROP TABLE IF EXISTS {outgoing_translations}; SET @saved_cs_client = @@character_set_client; SET character_set_client = utf8; diff --git a/modules/gallery/helpers/gallery_installer.php b/modules/gallery/helpers/gallery_installer.php index c3c3543c..0e5d29b9 100644 --- a/modules/gallery/helpers/gallery_installer.php +++ b/modules/gallery/helpers/gallery_installer.php @@ -259,7 +259,7 @@ class gallery_installer { module::set_var("gallery", "show_credits", 1); // @todo this string needs to be picked up by l10n_scanner module::set_var("gallery", "credits", "Powered by Gallery %version"); - module::set_version("gallery", 5); + module::set_version("gallery", 6); } static function upgrade($version) { -- cgit v1.2.3 From 177a854dbb540efa01048e31e655828ded9490b5 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Sun, 28 Jun 2009 19:23:19 -0700 Subject: Move the mysql_xxx() override function definitions inside installer::connect(), otherwise they're defined before we call check_environment, then we think we have mysql_query when we really don't. --- installer/installer.php | 52 ++++++++++++++++++++++++------------------------- 1 file changed, 26 insertions(+), 26 deletions(-) (limited to 'installer') diff --git a/installer/installer.php b/installer/installer.php index 9ba88bea..b0af561e 100644 --- a/installer/installer.php +++ b/installer/installer.php @@ -18,31 +18,6 @@ * Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */ -// We know that we have either mysql or mysqli. By default we use mysql functions, so if they're -// not defined then do the simplest thing which will work: remap them to their mysqli -// counterparts. -if (!function_exists("mysql_query")) { - function mysql_connect($host, $user, $pass) { - installer::$mysqli = new mysqli($host, $user, $pass); - // http://php.net/manual/en/mysqli.connect.php says to use mysqli_connect_error() instead of - // $mysqli->connect_error because of bugs before PHP 5.2.9 - $error = mysqli_connect_error(); - return empty($error); - } - function mysql_query($query) { - return installer::$mysqli->query($query); - } - function mysql_num_rows($result) { - return $result->num_rows; - } - function mysql_error() { - return installer::$mysqli->error; - } - function mysql_select_db($db) { - return installer::$mysqli->select_db($db); - } -} - class installer { static $mysqli; @@ -92,7 +67,32 @@ class installer { } static function connect($config) { - return @mysql_connect($config["host"], $config["user"], $config["password"]); + // We know that we have either mysql or mysqli. By default we use mysql functions, so if + // they're not defined then do the simplest thing which will work: remap them to their mysqli + // counterparts. + if (!function_exists("mysql_query")) { + function mysql_connect($host, $user, $pass) { + installer::$mysqli = new mysqli($host, $user, $pass); + // http://php.net/manual/en/mysqli.connect.php says to use mysqli_connect_error() instead of + // $mysqli->connect_error because of bugs before PHP 5.2.9 + $error = mysqli_connect_error(); + return empty($error); + } + function mysql_query($query) { + return installer::$mysqli->query($query); + } + function mysql_num_rows($result) { + return $result->num_rows; + } + function mysql_error() { + return installer::$mysqli->error; + } + function mysql_select_db($db) { + return installer::$mysqli->select_db($db); + } + } + + return mysql_connect($config["host"], $config["user"], $config["password"]); } static function select_db($config) { -- cgit v1.2.3 From b0bb107b7ebb5edbf3bec69ae2e716552eb1adf5 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Sun, 28 Jun 2009 19:26:41 -0700 Subject: Get rid of references to vestigial check.html.php page. --- installer/index.php | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'installer') diff --git a/installer/index.php b/installer/index.php index 317f27b8..a11c0b02 100644 --- a/installer/index.php +++ b/installer/index.php @@ -30,10 +30,6 @@ require(DOCROOT . "installer/installer.php"); if (PHP_SAPI == "cli") { include("cli.php"); } else { - if (@$_GET["page"] == "check") { - include("check.html.php"); - } else { - include("web.php"); - } + include("web.php"); } -- cgit v1.2.3 From b59e94e7dccc2ce1710ae98bda97ef537fd0c9b7 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Tue, 7 Jul 2009 07:32:36 -0700 Subject: Change references to Gallery 2 and Gallery 3 to consistently refer to Gallery n as opposed any variants of this. --- .htaccess | 2 +- installer/cli.php | 2 +- installer/views/already_installed.html.php | 2 +- installer/views/install.html.php | 2 +- installer/views/success.html.php | 2 +- modules/comment/views/comment.mrss.php | 2 +- modules/g2_import/helpers/g2_import.php | 18 +++++++++--------- modules/gallery/helpers/gallery_block.php | 2 +- modules/gallery/views/upgrader.html.php | 2 +- 9 files changed, 17 insertions(+), 17 deletions(-) (limited to 'installer') diff --git a/.htaccess b/.htaccess index f1996eed..08b9c5bb 100644 --- a/.htaccess +++ b/.htaccess @@ -36,7 +36,7 @@ # block below. You just need to change RewriteBase line to match your # Gallery 3 URL. Here are some examples: # -# Gallery3 URL RewriteBase line +# Gallery 3 URL RewriteBase line # ============= ==================== # http://example.com/gallery3 RewriteBase /gallery3 # http://example.com/~bob/photos RewriteBase /~bob/photos diff --git a/installer/cli.php b/installer/cli.php index e2fdffce..50845ea4 100644 --- a/installer/cli.php +++ b/installer/cli.php @@ -69,7 +69,7 @@ function oops($message) { print "==> " . $message; print "\n"; print "For help you can try:\n"; - print " * The Gallery3 FAQ - http://codex.gallery2.org/Gallery3:FAQ\n"; + print " * The Gallery 3 FAQ - http://codex.gallery2.org/Gallery3:FAQ\n"; print " * The Gallery Forums - http://gallery.menalto.com/forum\n"; print "\n\n** INSTALLATION FAILED **\n"; exit(1); diff --git a/installer/views/already_installed.html.php b/installer/views/already_installed.html.php index 0d7fc193..f6ac1bff 100644 --- a/installer/views/already_installed.html.php +++ b/installer/views/already_installed.html.php @@ -1,5 +1,5 @@

- Your Gallery3 install is complete. + Your Gallery 3 install is complete.

diff --git a/installer/views/install.html.php b/installer/views/install.html.php index 18060219..a0eddaf3 100644 --- a/installer/views/install.html.php +++ b/installer/views/install.html.php @@ -1,7 +1,7 @@ - Gallery3 Installer + Gallery 3 Installer diff --git a/installer/views/success.html.php b/installer/views/success.html.php index 4bca2fb1..e9ee9818 100644 --- a/installer/views/success.html.php +++ b/installer/views/success.html.php @@ -1,7 +1,7 @@

Success!

- Your Gallery3 install is complete! + Your Gallery 3 install is complete!

diff --git a/modules/comment/views/comment.mrss.php b/modules/comment/views/comment.mrss.php index e27bc44f..2b5b13c1 100644 --- a/modules/comment/views/comment.mrss.php +++ b/modules/comment/views/comment.mrss.php @@ -5,7 +5,7 @@ xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:fh="http://purl.org/syndication/history/1.0"> - gallery3 + Gallery 3 <?= p::clean($feed->title) ?> uri ?> description) ?> diff --git a/modules/g2_import/helpers/g2_import.php b/modules/g2_import/helpers/g2_import.php index e86558b7..0d72c139 100644 --- a/modules/g2_import/helpers/g2_import.php +++ b/modules/g2_import/helpers/g2_import.php @@ -54,14 +54,14 @@ class g2_import_Core { } /** - * Initialize the embedded Gallery2 instance. Call this before any other Gallery2 calls. + * Initialize the embedded Gallery 2 instance. Call this before any other Gallery 2 calls. */ static function init_embed($embed_path) { if (!is_file($embed_path)) { return false; } - // Gallery2 defines a class called Gallery. So does Gallery 3. They don't get along. So do + // Gallery 2 defines a class called Gallery. So does Gallery 3. They don't get along. So do // a total hack here and copy over a few critical files (embed.php, main.php, bootstrap.inc // and Gallery.class) and munge them so that we can rename the Gallery class to be // G2_Gallery. Is this retarded? Why yes it is. @@ -244,7 +244,7 @@ class g2_import_Core { break; case GROUP_SITE_ADMINS: - $message = t("Group 'Admin' does not exist in gallery3, skipping"); + $message = t("Group 'Admin' does not exist in Gallery 3, skipping"); break; // This is not a group in G3 case GROUP_EVERYBODY: @@ -343,7 +343,7 @@ class g2_import_Core { } if ($g2_album->getParentId() == null) { - return t("Skipping Gallery2 root album"); + return t("Skipping Gallery 2 root album"); } $parent_album = ORM::factory("item", self::map($g2_album->getParentId())); @@ -446,7 +446,7 @@ class g2_import_Core { $g2_type = $g2_item->getEntityType(); $corrupt = 0; if (!file_exists($g2_path)) { - // If the Gallery2 source image isn't available, this operation is going to fail. That can + // If the Gallery 2 source image isn't available, this operation is going to fail. That can // happen in cases where there's corruption in the source Gallery 2. In that case, fall // back on using a broken image. It's important that we import *something* otherwise // anything that refers to this item in Gallery 2 will have a dangling pointer in Gallery 3 @@ -665,8 +665,8 @@ class g2_import_Core { } /** - * If the thumbnails and resizes created for the Gallery2 photo match the dimensions of the - * ones we expect to create for Gallery3, then copy the files over instead of recreating them. + * If the thumbnails and resizes created for the Gallery 2 photo match the dimensions of the + * ones we expect to create for Gallery 3, then copy the files over instead of recreating them. */ static function copy_matching_thumbnails_and_resizes($item) { // We only operate on items that are being imported @@ -674,7 +674,7 @@ class g2_import_Core { return; } - // Precaution: if the Gallery2 item was watermarked, or we have the Gallery3 watermark module + // Precaution: if the Gallery 2 item was watermarked, or we have the Gallery 3 watermark module // active then we'd have to do something a lot more sophisticated here. For now, just skip // this step in those cases. // @todo we should probably use an API here, eventually. @@ -927,7 +927,7 @@ function g2() { $args = func_get_arg(0); $ret = array_shift($args); if ($ret) { - Kohana::log("error", "Gallery2 call failed with: " . $ret->getAsText()); + Kohana::log("error", "Gallery 2 call failed with: " . $ret->getAsText()); throw new Exception("@todo G2_FUNCTION_FAILED"); } if (count($args) == 1) { diff --git a/modules/gallery/helpers/gallery_block.php b/modules/gallery/helpers/gallery_block.php index a10f2bbf..b7816954 100644 --- a/modules/gallery/helpers/gallery_block.php +++ b/modules/gallery/helpers/gallery_block.php @@ -33,7 +33,7 @@ class gallery_block_Core { switch($block_id) { case "welcome": $block->css_id = "gWelcome"; - $block->title = t("Welcome to Gallery3"); + $block->title = t("Welcome to Gallery 3"); $block->content = new View("admin_block_welcome.html"); break; diff --git a/modules/gallery/views/upgrader.html.php b/modules/gallery/views/upgrader.html.php index f9e242a8..37578855 100644 --- a/modules/gallery/views/upgrader.html.php +++ b/modules/gallery/views/upgrader.html.php @@ -1,7 +1,7 @@ - <?= t("Gallery3 Upgrader") ?> + <?= t("Gallery 3 Upgrader") ?> " media="screen,print,projection" /> -- cgit v1.2.3 From 9f753a53f0371e60f62b8c88d39733d87b4af8f0 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Sat, 11 Jul 2009 05:30:39 -0700 Subject: MySQL 5 generates backwards compatible code-containing comments so: SET character_set_client = @saved_cs_client; becomes: /*!40101 SET character_set_client = @saved_cs_client */; for MySQL 4.0.1-01 and newer. --- installer/install.sql | 132 +++++++++++++++++++++++++------------------------- 1 file changed, 66 insertions(+), 66 deletions(-) (limited to 'installer') diff --git a/installer/install.sql b/installer/install.sql index 7da5fe68..d719d49d 100755 --- a/installer/install.sql +++ b/installer/install.sql @@ -1,6 +1,6 @@ DROP TABLE IF EXISTS {access_caches}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {access_caches} ( `id` int(9) NOT NULL auto_increment, `item_id` int(9) default NULL, @@ -12,11 +12,11 @@ CREATE TABLE {access_caches} ( `add_2` smallint(6) NOT NULL default '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {access_caches} VALUES (1,1,1,0,0,1,0,0); DROP TABLE IF EXISTS {access_intents}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {access_intents} ( `id` int(9) NOT NULL auto_increment, `item_id` int(9) default NULL, @@ -30,11 +30,11 @@ CREATE TABLE {access_intents} ( `add_2` tinyint(1) default NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {access_intents} VALUES (1,1,1,1,0,0,1,1,0,0); DROP TABLE IF EXISTS {caches}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {caches} ( `id` int(9) NOT NULL auto_increment, `key` varchar(255) NOT NULL, @@ -44,10 +44,10 @@ CREATE TABLE {caches} ( PRIMARY KEY (`id`), KEY `tags` (`tags`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS {comments}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {comments} ( `author_id` int(9) default NULL, `created` int(9) NOT NULL, @@ -73,10 +73,10 @@ CREATE TABLE {comments} ( `updated` int(9) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS {graphics_rules}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {graphics_rules} ( `id` int(9) NOT NULL auto_increment, `active` tinyint(1) default '0', @@ -87,11 +87,11 @@ CREATE TABLE {graphics_rules} ( `target` varchar(32) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {graphics_rules} VALUES (1,1,'a:3:{s:5:\"width\";i:200;s:6:\"height\";i:200;s:6:\"master\";i:2;}','gallery','resize',100,'thumb'),(2,1,'a:3:{s:5:\"width\";i:640;s:6:\"height\";i:480;s:6:\"master\";i:2;}','gallery','resize',100,'resize'); DROP TABLE IF EXISTS {groups}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {groups} ( `id` int(9) NOT NULL auto_increment, `name` char(64) default NULL, @@ -99,22 +99,22 @@ CREATE TABLE {groups} ( PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {groups} VALUES (1,'Everybody',1),(2,'Registered Users',1); DROP TABLE IF EXISTS {groups_users}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {groups_users} ( `group_id` int(9) NOT NULL, `user_id` int(9) NOT NULL, PRIMARY KEY (`group_id`,`user_id`), UNIQUE KEY `user_id` (`user_id`,`group_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {groups_users} VALUES (1,1),(1,2),(2,2); DROP TABLE IF EXISTS {incoming_translations}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {incoming_translations} ( `id` int(9) NOT NULL auto_increment, `key` char(32) NOT NULL, @@ -126,10 +126,10 @@ CREATE TABLE {incoming_translations} ( UNIQUE KEY `key` (`key`,`locale`), KEY `locale_key` (`locale`,`key`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS {items}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {items} ( `id` int(9) NOT NULL auto_increment, `album_cover_item_id` int(9) default NULL, @@ -167,11 +167,11 @@ CREATE TABLE {items} ( KEY `type` (`type`), KEY `random` (`rand_key`) ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {items} VALUES (1,NULL,NULL,UNIX_TIMESTAMP(),'',NULL,1,1,NULL,NULL,NULL,0,NULL,'',1,NULL,NULL,2,'weight','ASC',1,NULL,NULL,'Gallery','album',UNIX_TIMESTAMP(),0,1,NULL,1,1); DROP TABLE IF EXISTS {items_tags}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {items_tags} ( `id` int(9) NOT NULL auto_increment, `item_id` int(9) NOT NULL, @@ -180,10 +180,10 @@ CREATE TABLE {items_tags} ( KEY `tag_id` (`tag_id`,`id`), KEY `item_id` (`item_id`,`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS {logs}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {logs} ( `id` int(9) NOT NULL auto_increment, `category` varchar(64) default NULL, @@ -196,10 +196,10 @@ CREATE TABLE {logs} ( `user_id` int(9) default '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS {messages}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {messages} ( `id` int(9) NOT NULL auto_increment, `key` varchar(255) default NULL, @@ -208,10 +208,10 @@ CREATE TABLE {messages} ( PRIMARY KEY (`id`), UNIQUE KEY `key` (`key`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS {modules}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {modules} ( `id` int(9) NOT NULL auto_increment, `active` tinyint(1) default '0', @@ -220,11 +220,11 @@ CREATE TABLE {modules} ( PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {modules} VALUES (1,1,'gallery',6),(2,1,'user',1),(3,1,'comment',2),(4,1,'organize',1),(5,1,'info',1),(6,1,'rss',1),(7,1,'search',1),(8,1,'slideshow',1),(9,1,'tag',1); DROP TABLE IF EXISTS {outgoing_translations}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {outgoing_translations} ( `id` int(9) NOT NULL auto_increment, `base_revision` int(9) default NULL, @@ -236,10 +236,10 @@ CREATE TABLE {outgoing_translations} ( UNIQUE KEY `key` (`key`,`locale`), KEY `locale_key` (`locale`,`key`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS {permissions}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {permissions} ( `id` int(9) NOT NULL auto_increment, `display_name` varchar(64) default NULL, @@ -247,11 +247,11 @@ CREATE TABLE {permissions} ( PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {permissions} VALUES (1,'View','view'),(2,'View Full Size','view_full'),(3,'Edit','edit'),(4,'Add','add'); DROP TABLE IF EXISTS {search_records}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {search_records} ( `id` int(9) NOT NULL auto_increment, `item_id` int(9) default NULL, @@ -261,21 +261,21 @@ CREATE TABLE {search_records} ( KEY `item_id` (`item_id`), FULLTEXT KEY `data` (`data`) ) ENGINE=MyISAM AUTO_INCREMENT=2 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {search_records} VALUES (1,1,0,' Gallery'); DROP TABLE IF EXISTS {sessions}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {sessions} ( `session_id` varchar(127) NOT NULL, `data` text NOT NULL, `last_activity` int(10) unsigned NOT NULL, PRIMARY KEY (`session_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS {tags}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {tags} ( `id` int(9) NOT NULL auto_increment, `name` varchar(64) NOT NULL, @@ -283,10 +283,10 @@ CREATE TABLE {tags} ( PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS {tasks}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {tasks} ( `id` int(9) NOT NULL auto_increment, `callback` varchar(128) default NULL, @@ -301,10 +301,10 @@ CREATE TABLE {tasks} ( PRIMARY KEY (`id`), KEY `owner_id` (`owner_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; DROP TABLE IF EXISTS {themes}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {themes} ( `id` int(9) NOT NULL auto_increment, `name` varchar(64) default NULL, @@ -312,11 +312,11 @@ CREATE TABLE {themes} ( PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {themes} VALUES (1,'default',1),(2,'admin_default',1); DROP TABLE IF EXISTS {users}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {users} ( `id` int(9) NOT NULL auto_increment, `name` varchar(32) NOT NULL, @@ -334,11 +334,11 @@ CREATE TABLE {users} ( UNIQUE KEY `name` (`name`), UNIQUE KEY `hash` (`hash`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {users} VALUES (1,'guest','Guest User','',0,0,NULL,0,1,NULL,NULL,NULL),(2,'admin','Gallery Administrator','',0,0,NULL,1,0,NULL,NULL,NULL); DROP TABLE IF EXISTS {vars}; -SET @saved_cs_client = @@character_set_client; -SET character_set_client = utf8; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; CREATE TABLE {vars} ( `id` int(9) NOT NULL auto_increment, `module_name` varchar(64) NOT NULL, @@ -347,5 +347,5 @@ CREATE TABLE {vars} ( PRIMARY KEY (`id`), UNIQUE KEY `module_name` (`module_name`,`name`) ) ENGINE=InnoDB AUTO_INCREMENT=28 DEFAULT CHARSET=utf8; -SET character_set_client = @saved_cs_client; +/*!40101 SET character_set_client = @saved_cs_client */; INSERT INTO {vars} VALUES (1,'gallery','active_site_theme','default'),(2,'gallery','active_admin_theme','admin_default'),(3,'gallery','page_size','9'),(4,'gallery','thumb_size','200'),(5,'gallery','resize_size','640'),(6,'gallery','default_locale','en_US'),(7,'gallery','image_quality','75'),(9,'gallery','blocks_dashboard_sidebar','a:4:{i:2;a:2:{i:0;s:7:\"gallery\";i:1;s:11:\"block_adder\";}i:3;a:2:{i:0;s:7:\"gallery\";i:1;s:5:\"stats\";}i:4;a:2:{i:0;s:7:\"gallery\";i:1;s:13:\"platform_info\";}i:5;a:2:{i:0;s:7:\"gallery\";i:1;s:12:\"project_news\";}}'),(14,'gallery','blocks_dashboard_center','a:4:{i:6;a:2:{i:0;s:7:\"gallery\";i:1;s:7:\"welcome\";}i:7;a:2:{i:0;s:7:\"gallery\";i:1;s:12:\"photo_stream\";}i:8;a:2:{i:0;s:7:\"gallery\";i:1;s:11:\"log_entries\";}i:9;a:2:{i:0;s:7:\"comment\";i:1;s:15:\"recent_comments\";}}'),(17,'gallery','version','3.0 pre beta 2 (git)'),(18,'gallery','choose_default_tookit','1'),(19,'gallery','date_format','Y-M-d'),(20,'gallery','date_time_format','Y-M-d H:i:s'),(21,'gallery','time_format','H:i:s'),(22,'gallery','show_credits','1'),(23,'gallery','credits','Powered by Gallery %version'),(25,'comment','spam_caught','0'); -- cgit v1.2.3 From 6281ed03d54a010efdee3988a893cfcd7f3663b5 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Sat, 11 Jul 2009 05:36:31 -0700 Subject: Turn off extended inserts when creating install.sql so that it's easier to see what's changed. --- installer/install.sql | 49 ++++++++++++++++++++++++++------ modules/gallery/controllers/packager.php | 4 +-- 2 files changed, 43 insertions(+), 10 deletions(-) (limited to 'installer') diff --git a/installer/install.sql b/installer/install.sql index d719d49d..bda576d1 100755 --- a/installer/install.sql +++ b/installer/install.sql @@ -88,7 +88,8 @@ CREATE TABLE {graphics_rules} ( PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -INSERT INTO {graphics_rules} VALUES (1,1,'a:3:{s:5:\"width\";i:200;s:6:\"height\";i:200;s:6:\"master\";i:2;}','gallery','resize',100,'thumb'),(2,1,'a:3:{s:5:\"width\";i:640;s:6:\"height\";i:480;s:6:\"master\";i:2;}','gallery','resize',100,'resize'); +INSERT INTO {graphics_rules} VALUES (1,1,'a:3:{s:5:\"width\";i:200;s:6:\"height\";i:200;s:6:\"master\";i:2;}','gallery','resize',100,'thumb'); +INSERT INTO {graphics_rules} VALUES (2,1,'a:3:{s:5:\"width\";i:640;s:6:\"height\";i:480;s:6:\"master\";i:2;}','gallery','resize',100,'resize'); DROP TABLE IF EXISTS {groups}; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; @@ -100,7 +101,8 @@ CREATE TABLE {groups} ( UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -INSERT INTO {groups} VALUES (1,'Everybody',1),(2,'Registered Users',1); +INSERT INTO {groups} VALUES (1,'Everybody',1); +INSERT INTO {groups} VALUES (2,'Registered Users',1); DROP TABLE IF EXISTS {groups_users}; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; @@ -111,7 +113,9 @@ CREATE TABLE {groups_users} ( UNIQUE KEY `user_id` (`user_id`,`group_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -INSERT INTO {groups_users} VALUES (1,1),(1,2),(2,2); +INSERT INTO {groups_users} VALUES (1,1); +INSERT INTO {groups_users} VALUES (1,2); +INSERT INTO {groups_users} VALUES (2,2); DROP TABLE IF EXISTS {incoming_translations}; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; @@ -221,7 +225,15 @@ CREATE TABLE {modules} ( UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -INSERT INTO {modules} VALUES (1,1,'gallery',6),(2,1,'user',1),(3,1,'comment',2),(4,1,'organize',1),(5,1,'info',1),(6,1,'rss',1),(7,1,'search',1),(8,1,'slideshow',1),(9,1,'tag',1); +INSERT INTO {modules} VALUES (1,1,'gallery',6); +INSERT INTO {modules} VALUES (2,1,'user',1); +INSERT INTO {modules} VALUES (3,1,'comment',2); +INSERT INTO {modules} VALUES (4,1,'organize',1); +INSERT INTO {modules} VALUES (5,1,'info',1); +INSERT INTO {modules} VALUES (6,1,'rss',1); +INSERT INTO {modules} VALUES (7,1,'search',1); +INSERT INTO {modules} VALUES (8,1,'slideshow',1); +INSERT INTO {modules} VALUES (9,1,'tag',1); DROP TABLE IF EXISTS {outgoing_translations}; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; @@ -248,7 +260,10 @@ CREATE TABLE {permissions} ( UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -INSERT INTO {permissions} VALUES (1,'View','view'),(2,'View Full Size','view_full'),(3,'Edit','edit'),(4,'Add','add'); +INSERT INTO {permissions} VALUES (1,'View','view'); +INSERT INTO {permissions} VALUES (2,'View Full Size','view_full'); +INSERT INTO {permissions} VALUES (3,'Edit','edit'); +INSERT INTO {permissions} VALUES (4,'Add','add'); DROP TABLE IF EXISTS {search_records}; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; @@ -313,7 +328,8 @@ CREATE TABLE {themes} ( UNIQUE KEY `name` (`name`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -INSERT INTO {themes} VALUES (1,'default',1),(2,'admin_default',1); +INSERT INTO {themes} VALUES (1,'default',1); +INSERT INTO {themes} VALUES (2,'admin_default',1); DROP TABLE IF EXISTS {users}; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; @@ -335,7 +351,8 @@ CREATE TABLE {users} ( UNIQUE KEY `hash` (`hash`) ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -INSERT INTO {users} VALUES (1,'guest','Guest User','',0,0,NULL,0,1,NULL,NULL,NULL),(2,'admin','Gallery Administrator','',0,0,NULL,1,0,NULL,NULL,NULL); +INSERT INTO {users} VALUES (1,'guest','Guest User','',0,0,NULL,0,1,NULL,NULL,NULL); +INSERT INTO {users} VALUES (2,'admin','Gallery Administrator','',0,0,NULL,1,0,NULL,NULL,NULL); DROP TABLE IF EXISTS {vars}; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; @@ -348,4 +365,20 @@ CREATE TABLE {vars} ( UNIQUE KEY `module_name` (`module_name`,`name`) ) ENGINE=InnoDB AUTO_INCREMENT=28 DEFAULT CHARSET=utf8; /*!40101 SET character_set_client = @saved_cs_client */; -INSERT INTO {vars} VALUES (1,'gallery','active_site_theme','default'),(2,'gallery','active_admin_theme','admin_default'),(3,'gallery','page_size','9'),(4,'gallery','thumb_size','200'),(5,'gallery','resize_size','640'),(6,'gallery','default_locale','en_US'),(7,'gallery','image_quality','75'),(9,'gallery','blocks_dashboard_sidebar','a:4:{i:2;a:2:{i:0;s:7:\"gallery\";i:1;s:11:\"block_adder\";}i:3;a:2:{i:0;s:7:\"gallery\";i:1;s:5:\"stats\";}i:4;a:2:{i:0;s:7:\"gallery\";i:1;s:13:\"platform_info\";}i:5;a:2:{i:0;s:7:\"gallery\";i:1;s:12:\"project_news\";}}'),(14,'gallery','blocks_dashboard_center','a:4:{i:6;a:2:{i:0;s:7:\"gallery\";i:1;s:7:\"welcome\";}i:7;a:2:{i:0;s:7:\"gallery\";i:1;s:12:\"photo_stream\";}i:8;a:2:{i:0;s:7:\"gallery\";i:1;s:11:\"log_entries\";}i:9;a:2:{i:0;s:7:\"comment\";i:1;s:15:\"recent_comments\";}}'),(17,'gallery','version','3.0 pre beta 2 (git)'),(18,'gallery','choose_default_tookit','1'),(19,'gallery','date_format','Y-M-d'),(20,'gallery','date_time_format','Y-M-d H:i:s'),(21,'gallery','time_format','H:i:s'),(22,'gallery','show_credits','1'),(23,'gallery','credits','Powered by Gallery %version'),(25,'comment','spam_caught','0'); +INSERT INTO {vars} VALUES (1,'gallery','active_site_theme','default'); +INSERT INTO {vars} VALUES (2,'gallery','active_admin_theme','admin_default'); +INSERT INTO {vars} VALUES (3,'gallery','page_size','9'); +INSERT INTO {vars} VALUES (4,'gallery','thumb_size','200'); +INSERT INTO {vars} VALUES (5,'gallery','resize_size','640'); +INSERT INTO {vars} VALUES (6,'gallery','default_locale','en_US'); +INSERT INTO {vars} VALUES (7,'gallery','image_quality','75'); +INSERT INTO {vars} VALUES (9,'gallery','blocks_dashboard_sidebar','a:4:{i:2;a:2:{i:0;s:7:\"gallery\";i:1;s:11:\"block_adder\";}i:3;a:2:{i:0;s:7:\"gallery\";i:1;s:5:\"stats\";}i:4;a:2:{i:0;s:7:\"gallery\";i:1;s:13:\"platform_info\";}i:5;a:2:{i:0;s:7:\"gallery\";i:1;s:12:\"project_news\";}}'); +INSERT INTO {vars} VALUES (14,'gallery','blocks_dashboard_center','a:4:{i:6;a:2:{i:0;s:7:\"gallery\";i:1;s:7:\"welcome\";}i:7;a:2:{i:0;s:7:\"gallery\";i:1;s:12:\"photo_stream\";}i:8;a:2:{i:0;s:7:\"gallery\";i:1;s:11:\"log_entries\";}i:9;a:2:{i:0;s:7:\"comment\";i:1;s:15:\"recent_comments\";}}'); +INSERT INTO {vars} VALUES (17,'gallery','version','3.0 pre beta 2 (git)'); +INSERT INTO {vars} VALUES (18,'gallery','choose_default_tookit','1'); +INSERT INTO {vars} VALUES (19,'gallery','date_format','Y-M-d'); +INSERT INTO {vars} VALUES (20,'gallery','date_time_format','Y-M-d H:i:s'); +INSERT INTO {vars} VALUES (21,'gallery','time_format','H:i:s'); +INSERT INTO {vars} VALUES (22,'gallery','show_credits','1'); +INSERT INTO {vars} VALUES (23,'gallery','credits','Powered by Gallery %version'); +INSERT INTO {vars} VALUES (25,'comment','spam_caught','0'); diff --git a/modules/gallery/controllers/packager.php b/modules/gallery/controllers/packager.php index da0a7983..7b4d68f6 100644 --- a/modules/gallery/controllers/packager.php +++ b/modules/gallery/controllers/packager.php @@ -98,7 +98,7 @@ class Packager_Controller extends Controller { print "$sql_file is not writeable"; return; } - $command = "mysqldump --compact --add-drop-table -h{$conn['host']} " . + $command = "mysqldump --compact --skip-extended-insert --add-drop-table -h{$conn['host']} " . "-u{$conn['user']} $pass {$conn['database']} > $sql_file"; exec($command, $output, $status); if ($status) { @@ -153,7 +153,7 @@ class Packager_Controller extends Controller { $paths[] = "VARPATH . \"" . substr($name, strlen(VARPATH)) . "\""; } else { // @todo: serialize non-directories - print "Unknown file: $name"; + print "IGNORING FILE: $name\n"; return; } } -- cgit v1.2.3 From d192f2f1bc1227938d3144381ef311c7e07b47b0 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Wed, 15 Jul 2009 20:38:37 +0800 Subject: Fix for ticket #545. Changed get_db_info.html.php to not display the database information request form until the var directory is successfully tested as writable. This prevents users from thinking they can enter the database information prior to successfully accessing the var directory. Signed-off-by: Tim Almdal --- installer/views/get_db_info.html.php | 2 ++ 1 file changed, 2 insertions(+) (limited to 'installer') diff --git a/installer/views/get_db_info.html.php b/installer/views/get_db_info.html.php index 7835f246..94c19585 100644 --- a/installer/views/get_db_info.html.php +++ b/installer/views/get_db_info.html.php @@ -26,6 +26,7 @@ +
Database @@ -87,3 +88,4 @@
+ -- cgit v1.2.3 From f6973431b7f8df24c081a03c7c989f621ab2a708 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Wed, 15 Jul 2009 21:48:47 +0800 Subject: Fix for ticket #544. * Separate the portion of get_db_info.html.php that displays the status of the var directory into a separate view var_dir_status.html.php * Change the processing to always generate the database information request screen unless there is an environment error, the var directory is not writable and the install was successful Signed-off-by: Tim Almdal --- installer/views/get_db_info.html.php | 43 ++++----------------------------- installer/views/install.html.php | 3 ++- installer/views/var_dir_status.html.php | 30 +++++++++++++++++++++++ installer/web.php | 21 ++++++++++------ 4 files changed, 50 insertions(+), 47 deletions(-) create mode 100644 installer/views/var_dir_status.html.php (limited to 'installer') diff --git a/installer/views/get_db_info.html.php b/installer/views/get_db_info.html.php index 94c19585..adc775a4 100644 --- a/installer/views/get_db_info.html.php +++ b/installer/views/get_db_info.html.php @@ -1,32 +1,4 @@ -

Welcome!

-

- Installing Gallery is very easy. We just need to know how to talk - to your MySQL database, and we need a place to store your photos on - your web host. -

- - -
- Photo Storage - -

- We're having trouble creating a place for your photos. Can you - help? Please create a directory called "var" using mkdir var in your - gallery3 directory, then run chmod 777 var. That - should fix it. -

- Check again -

- -

- We've found a place to store your photos: - -

- -
- -
Database @@ -41,7 +13,7 @@ Database Name - + @@ -49,7 +21,7 @@ User - + @@ -57,7 +29,7 @@ Password - + @@ -65,7 +37,7 @@ Host - + @@ -73,19 +45,14 @@ Table Prefix - + - - - (Please fix the photo storage problem before continuing) -
- diff --git a/installer/views/install.html.php b/installer/views/install.html.php index a0eddaf3..31112c28 100644 --- a/installer/views/install.html.php +++ b/installer/views/install.html.php @@ -8,7 +8,8 @@
- + +