Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

35 lines (31 sloc) 1.229 kb
<?php
function book_upgrade($oldversion) {
/// This function does anything necessary to upgrade
/// older versions to match current functionality
global $CFG;
if ($oldversion < 2004060600) {
execute_sql ("ALTER TABLE {$CFG->prefix}book
CHANGE intro summary TEXT NOT NULL;
");
}
if ($oldversion < 2004071100) {
execute_sql ("ALTER TABLE {$CFG->prefix}book_chapters
ADD importsrc VARCHAR(255) NOT NULL DEFAULT '' AFTER timemodified;
");
}
if ($oldversion < 2004071201) {
execute_sql ("UPDATE {$CFG->prefix}log_display
SET action = 'print'
WHERE action = 'prINT';
");
}
if ($oldversion < 2004072400) {
execute_sql ("ALTER TABLE {$CFG->prefix}book
ADD disableprinting TINYINT(2) UNSIGNED NOT NULL DEFAULT '0' AFTER numbering;
");
execute_sql ("ALTER TABLE {$CFG->prefix}book
ADD customtitles TINYINT(2) UNSIGNED NOT NULL DEFAULT '0' AFTER disableprinting;
");
}
return true;
}
Jump to Line
Something went wrong with that request. Please try again.