| [ Index ] |
PHP Cross Reference of MyBB 1.8.40 |
[Summary view] [Print] [Text view]
1 <?php 2 /** 3 * MyBB 1.8 4 * Copyright 2014 MyBB Group, All Rights Reserved 5 * 6 * Website: http://www.mybb.com 7 * License: http://www.mybb.com/about/license 8 * 9 */ 10 11 /** 12 * Upgrade Script: 1.6.6 13 */ 14 15 16 $upgrade_detail = array( 17 "revert_all_templates" => 0, 18 "revert_all_themes" => 0, 19 "revert_all_settings" => 0 20 ); 21 22 function upgrade23_dbchanges() 23 { 24 global $db, $output; 25 26 $output->print_header("Updating Database"); 27 echo "<p>Performing necessary upgrade queries...</p>"; 28 29 if($db->field_exists('canusecustomtools', 'moderators')) 30 { 31 $db->drop_column('moderators', 'canusecustomtools'); 32 } 33 34 if($db->field_exists('cansendemailoverride', 'usergroups')) 35 { 36 $db->drop_column('usergroups', 'cansendemailoverride'); 37 } 38 39 switch($db->type) 40 { 41 case "pgsql": 42 case "sqlite": 43 $db->add_column('moderators', 'canusecustomtools', "int NOT NULL default '0'"); 44 $db->add_column('usergroups', 'cansendemailoverride', "int NOT NULL default '0'"); 45 break; 46 default: 47 $db->add_column('moderators', 'canusecustomtools', "int(1) NOT NULL default '0'"); 48 $db->add_column('usergroups', 'cansendemailoverride', "int(1) NOT NULL default '0'"); 49 break; 50 } 51 52 $db->update_query('moderators', array('canusecustomtools' => 1), "canmanagethreads = '1'"); 53 54 $output->print_contents("<p>Click next to continue with the upgrade process.</p>"); 55 $output->print_footer("23_done"); 56 }
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
| 2005 - 2021 © MyBB.de | Alle Rechte vorbehalten! | Sponsor: netcup | Cross-referenced by PHPXref |