[geeklog-cvs] geeklog: Upgrading from Geeklog 1.5.2 did not extend the pid (po...
geeklog-cvs at lists.geeklog.net
geeklog-cvs at lists.geeklog.net
Sat Sep 19 11:58:47 EDT 2009
details: http://project.geeklog.net/cgi-bin/hgweb.cgi/rev/55608273b965
changeset: 7327:55608273b965
user: Dirk Haun <dirk at haun-online.de>
date: Sat Sep 19 17:58:30 2009 +0200
description:
Upgrading from Geeklog 1.5.2 did not extend the pid (poll id) to 40 characters. Let's try that again when upgrading to 1.6.1 ...
diffstat:
plugins/polls/functions.inc | 12 +++++-------
plugins/polls/sql/mssql_updates.php | 11 +++++++----
plugins/polls/sql/mysql_updates.php | 10 ++++++----
public_html/docs/history | 4 ++++
4 files changed, 22 insertions(+), 15 deletions(-)
diffs (89 lines):
diff -r 39be7f133232 -r 55608273b965 plugins/polls/functions.inc
--- a/plugins/polls/functions.inc Mon Sep 14 20:40:59 2009 -0400
+++ b/plugins/polls/functions.inc Sat Sep 19 17:58:30 2009 +0200
@@ -1151,15 +1151,13 @@
while (! $done) {
switch ($current_version) {
case '2.0.1':
- if (isset($_UPDATES[$current_version])) {
- $_SQL = $_UPDATES[$current_version];
- foreach ($_SQL as $sql) {
- DB_query($sql);
- }
- }
-
+ $current_version = '2.0.2';
+ break;
+
+ case '2.0.2':
$current_version = '2.1.0';
break;
+
case '2.1.0':
if (isset($_UPDATES[$current_version])) {
$_SQL = $_UPDATES[$current_version];
diff -r 39be7f133232 -r 55608273b965 plugins/polls/sql/mssql_updates.php
--- a/plugins/polls/sql/mssql_updates.php Mon Sep 14 20:40:59 2009 -0400
+++ b/plugins/polls/sql/mssql_updates.php Sat Sep 19 17:58:30 2009 +0200
@@ -34,16 +34,19 @@
$_UPDATES = array(
- '2.0.1' => array(
+ '2.1.0' => array(
+ // These pid changes should have happened when upgrading from 2.0.2
+ // to 2.1.0 but were previously listed for an upgrade from 2.0.1 and
+ // therefore may have not been applied. Apply again to be sure.
"ALTER TABLE {$_TABLES['pollanswers']} ALTER COLUMN [pid] VARCHARS(40)",
"ALTER TABLE {$_TABLES['pollquestions']} ALTER COLUMN [pid] VARCHARS(40)",
"ALTER TABLE {$_TABLES['polltopics']} ALTER COLUMN [pid] VARCHARS(40)",
- "ALTER TABLE {$_TABLES['pollvoters']} ALTER COLUMN [pid] VARCHARS(40)"
- ),
+ "ALTER TABLE {$_TABLES['pollvoters']} ALTER COLUMN [pid] VARCHARS(40)",
- '2.1.0' => array(
+ // New field post-2.1.0
"ALTER TABLE {$_TABLES['polltopics']} ADD meta_description [varchar] (5000) COLLATE SQL_Latin1_General_CP1_CI_AS NULL AFTER topic, ADD meta_keywords [meta_keywords] [varchar] (5000) COLLATE SQL_Latin1_General_CP1_CI_AS NULL AFTER meta_description"
)
+
);
function update_ConfValues_2_1_0()
diff -r 39be7f133232 -r 55608273b965 plugins/polls/sql/mysql_updates.php
--- a/plugins/polls/sql/mysql_updates.php Mon Sep 14 20:40:59 2009 -0400
+++ b/plugins/polls/sql/mysql_updates.php Sat Sep 19 17:58:30 2009 +0200
@@ -34,14 +34,16 @@
$_UPDATES = array(
- '2.0.1' => array(
+ '2.1.0' => array(
+ // These pid changes should have happened when upgrading from 2.0.2
+ // to 2.1.0 but were previously listed for an upgrade from 2.0.1 and
+ // therefore may have not been applied. Apply again to be sure.
"ALTER TABLE {$_TABLES['pollanswers']} CHANGE pid pid varchar(40) NOT NULL default ''",
"ALTER TABLE {$_TABLES['pollquestions']} CHANGE pid pid varchar(40) NOT NULL default ''",
"ALTER TABLE {$_TABLES['polltopics']} CHANGE pid pid varchar(40) NOT NULL default ''",
- "ALTER TABLE {$_TABLES['pollvoters']} CHANGE pid pid varchar(40) NOT NULL default ''"
- ),
+ "ALTER TABLE {$_TABLES['pollvoters']} CHANGE pid pid varchar(40) NOT NULL default ''",
- '2.1.0' => array(
+ // New field post-2.1.0
"ALTER TABLE {$_TABLES['polltopics']} ADD meta_description TEXT NULL AFTER topic, ADD meta_keywords TEXT NULL AFTER meta_description"
)
diff -r 39be7f133232 -r 55608273b965 public_html/docs/history
--- a/public_html/docs/history Mon Sep 14 20:40:59 2009 -0400
+++ b/public_html/docs/history Sat Sep 19 17:58:30 2009 +0200
@@ -74,6 +74,10 @@
Polls Plugin
------------
+- When upgrading from Geeklog 1.5.2, the length of the poll IDs was not extended
+ to 40 characters - only fresh installs of Geeklog 1.6.0 and upgrades from
+ older versions worked correctly (cf. feature request #0000754) [Dirk]
+- Added support for meta tags and meta keywords, provided by Tom Homer
- Introduced [poll:], [poll_vote:], and [poll_result:] autotags, allowing to
embed polls where autotags are allowed, provided by Tom Homer
More information about the geeklog-cvs
mailing list