function sp_bump_build($build, $section) { if ($build < $section) { # bump the build number sp_response($section); } }
$section = 12758; if ($build < $section) { # update autoupdate meta to not have full url, just the ahah loader info $spMeta = spdb_table(SFMETA, 'meta_type="autoupdate"'); if (!empty($spMeta)) { foreach ($spMeta as $meta) { if (!empty($meta)) { $value = unserialize($meta->meta_value); $value[1] = str_replace(site_url('', 'http') . '/index.php?', '', $value[1]); $value[1] = str_replace(site_url('', 'https') . '/index.php?', '', $value[1]); sp_update_sfmeta('autoupdate', $meta->meta_key, $value, $meta->meta_id, $meta->autoload); } } } sp_response($section); } $section = 12760; if ($build < $section) { # convert table collation $tables = sp_get_option('installed_tables'); foreach ($tables as $table) { sp_convert_table_to_utf8mb4($table); } sp_response($section); } sp_bump_build($build, 12968); # Start of Upgrade Routines - 5.5.8 ============================================================ sp_bump_build($build, 13000); # ****** IMPORTANT: THE FINAL $section valuse MUST be the same as the SPBUILD constant # ****** for the Upgrade to complete correctly die;