Vergleich install/resources/upgrade12.php - 1.8.4 - 1.8.37

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 177Zeile 177
			echo "<input type=\"hidden\" name=\"{$key}\" value=\"{$val}\" />";
}
global $footer_extra;

			echo "<input type=\"hidden\" name=\"{$key}\" value=\"{$val}\" />";
}
global $footer_extra;

		$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

		$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

		$output->print_footer($next_act);
}
else

		$output->print_footer($next_act);
}
else

Zeile 189Zeile 189
		echo "<p><strong>The integrer conversion process is now complete.</strong></p>";
echo "<p>Click next to continue with the upgrade process.</p>";
global $footer_extra;

		echo "<p><strong>The integrer conversion process is now complete.</strong></p>";
echo "<p>Click next to continue with the upgrade process.</p>";
global $footer_extra;

		$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

		$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer($next_act);
}


$output->print_footer($next_act);
}

Zeile 213Zeile 213
	$output->print_contents($contents);

global $footer_extra;

	$output->print_contents($contents);

global $footer_extra;

	$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer("12_dbchanges_post1");
}


$output->print_footer("12_dbchanges_post1");
}

Zeile 238Zeile 238
	$output->print_contents($contents);

global $footer_extra;

	$output->print_contents($contents);

global $footer_extra;

	$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer("12_dbchanges_post2");
}


$output->print_footer("12_dbchanges_post2");
}

Zeile 274Zeile 274
	$output->print_contents($contents);

global $footer_extra;

	$output->print_contents($contents);

global $footer_extra;

	$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer("12_dbchanges_user");
}


$output->print_footer("12_dbchanges_user");
}

Zeile 300Zeile 300
	$output->print_contents($contents);

global $footer_extra;

	$output->print_contents($contents);

global $footer_extra;

	$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer("12_dbchanges2");
}


$output->print_footer("12_dbchanges2");
}

Zeile 557Zeile 557

include_once MYBB_ROOT."inc/functions_task.php";
$tasks = file_get_contents(INSTALL_ROOT.'resources/tasks.xml');


include_once MYBB_ROOT."inc/functions_task.php";
$tasks = file_get_contents(INSTALL_ROOT.'resources/tasks.xml');

	$parser = new XMLParser($tasks);

	$parser = create_xml_parser($tasks);

	$parser->collapse_dups = 0;
$tree = $parser->get_tree();


	$parser->collapse_dups = 0;
$tree = $parser->get_tree();


Zeile 762Zeile 762
	$db->update_query("settings", array('value' => 'classic'), "name='postlayout' AND value != 'horizontal'");

$db->update_query("settings", array('optionscode' => $db->escape_string('php

	$db->update_query("settings", array('value' => 'classic'), "name='postlayout' AND value != 'horizontal'");

$db->update_query("settings", array('optionscode' => $db->escape_string('php

<select name=\"upsetting[{$setting[\'name\']}]\"><option value=\"standard\">".($lang->setting_searchtype_standard?$lang->setting_searchtype_standard:"Standard")."</option>".($db->supports_fulltext("threads") && $db->supports_fulltext_boolean("posts")?"<option value=\"fulltext\"".($setting[\'value\']=="fulltext"?" selected=\"selected\"":"").">".($lang->setting_searchtype_fulltext?$lang->setting_searchtype_fulltext:"Full Text")."</option>":"")."</select>')), "name='searchtype'", 1);

<select name=\"upsetting[{$setting[\'name\']}]\"><option value=\"standard\">".(isset($lang->setting_searchtype_standard)?$lang->setting_searchtype_standard:"Standard")."</option>".($db->supports_fulltext("threads") && $db->supports_fulltext_boolean("posts")?"<option value=\"fulltext\"".($setting[\'value\']=="fulltext"?" selected=\"selected\"":"").">".(isset($lang->setting_searchtype_fulltext)?$lang->setting_searchtype_fulltext:"Full Text")."</option>":"")."</select>')), "name='searchtype'", 1);


$contents = "Done</p>";
$contents .= "<p>Click next to continue with the upgrade process.</p>";
$output->print_contents($contents);

global $footer_extra;


$contents = "Done</p>";
$contents .= "<p>Click next to continue with the upgrade process.</p>";
$output->print_contents($contents);

global $footer_extra;

	$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer("12_dbchanges3");
}


$output->print_footer("12_dbchanges3");
}

Zeile 845Zeile 845
	$output->print_contents($contents);

global $footer_extra;

	$output->print_contents($contents);

global $footer_extra;

	$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer("12_dbchanges4");
}


$output->print_footer("12_dbchanges4");
}

Zeile 914Zeile 914
	}

$adminoptions = file_get_contents(INSTALL_ROOT.'resources/adminoptions.xml');

	}

$adminoptions = file_get_contents(INSTALL_ROOT.'resources/adminoptions.xml');

	$parser = new XMLParser($adminoptions);

	$parser = create_xml_parser($adminoptions);

	$parser->collapse_dups = 0;
$tree = $parser->get_tree();


	$parser->collapse_dups = 0;
$tree = $parser->get_tree();


Zeile 1063Zeile 1063
	$db->write_query("ALTER TABLE ".TABLE_PREFIX."adminoptions ADD defaultviews TEXT NOT NULL");
$db->update_query("adminoptions", array('defaultviews' => my_serialize(array('user' => 1))));


	$db->write_query("ALTER TABLE ".TABLE_PREFIX."adminoptions ADD defaultviews TEXT NOT NULL");
$db->update_query("adminoptions", array('defaultviews' => my_serialize(array('user' => 1))));


	require_once MYBB_ROOT."inc/functions_rebuild.php";
rebuild_stats();






	$query = $db->simple_select("forums", "SUM(threads) AS numthreads, SUM(posts) AS numposts, SUM(unapprovedthreads) AS numunapprovedthreads, SUM(unapprovedposts) AS numunapprovedposts");
$stats = $db->fetch_array($query);

$query = $db->simple_select("users", "COUNT(uid) AS users");
$stats['numusers'] = $db->fetch_field($query, 'users');

update_stats($stats, true);


$contents = "Done</p>";
$contents .= "<p>Click next to continue with the upgrade process.</p>";
$output->print_contents($contents);


$contents = "Done</p>";
$contents .= "<p>Click next to continue with the upgrade process.</p>";
$output->print_contents($contents);





	global $footer_extra;

	global $footer_extra;

	$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer("12_dbchanges5");
}


$output->print_footer("12_dbchanges5");
}

Zeile 1079Zeile 1084
function upgrade12_dbchanges5()
{
global $db, $output, $mybb;

function upgrade12_dbchanges5()
{
global $db, $output, $mybb;





	$output->print_header("Performing Queries");

echo "<p>Performing necessary upgrade queries..</p>";

	$output->print_header("Performing Queries");

echo "<p>Performing necessary upgrade queries..</p>";

Zeile 1164Zeile 1169

$db->write_query("CREATE TABLE ".TABLE_PREFIX."threadviews (
tid int unsigned NOT NULL default '0'


$db->write_query("CREATE TABLE ".TABLE_PREFIX."threadviews (
tid int unsigned NOT NULL default '0'

	) ENGINE=MyISAM{$collation};");

	) ENGINE=MyISAM{$collation};");


$db->write_query("CREATE TABLE ".TABLE_PREFIX."calendars (
cid int unsigned NOT NULL auto_increment,


$db->write_query("CREATE TABLE ".TABLE_PREFIX."calendars (
cid int unsigned NOT NULL auto_increment,

Zeile 1234Zeile 1239
	) ENGINE=MyISAM{$collation};");

$views = file_get_contents(INSTALL_ROOT.'resources/adminviews.xml');

	) ENGINE=MyISAM{$collation};");

$views = file_get_contents(INSTALL_ROOT.'resources/adminviews.xml');

	$parser = new XMLParser($views);

	$parser = create_xml_parser($views);

	$parser->collapse_dups = 0;
$tree = $parser->get_tree();


	$parser->collapse_dups = 0;
$tree = $parser->get_tree();


Zeile 1274Zeile 1279
		$db->insert_query("adminviews", $new_view);
$view_count++;
}

		$db->insert_query("adminviews", $new_view);
$view_count++;
}


$avatardimensions = str_replace('x', '|', my_strtolower($mybb->settings['postmaxavatarsize']));

 

$db->simple_select("users", "uid", "avatar != '' AND avatardimensions = ''");
while($user = $db->fetch_array($query))
{
$db->update_query("users", array('avatardimensions' => $avatardimensions), "uid='{$user['uid']}'", 1);
}


$db->simple_select("users", "uid", "avatar != '' AND avatardimensions = ''");
while($user = $db->fetch_array($query))
{
$db->update_query("users", array('avatardimensions' => $avatardimensions), "uid='{$user['uid']}'", 1);
}





	$contents = "Done</p>";
$contents .= "<p>Click next to continue with the upgrade process.</p>";
$output->print_contents($contents);

	$contents = "Done</p>";
$contents .= "<p>Click next to continue with the upgrade process.</p>";
$output->print_contents($contents);





	global $footer_extra;

	global $footer_extra;

	$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer("12_redoconfig");
}


$output->print_footer("12_redoconfig");
}

Zeile 1317Zeile 1320
		if(!$config['memcache_host'])
{
$config['memcache_host'] = "localhost";

		if(!$config['memcache_host'])
{
$config['memcache_host'] = "localhost";

		}


		}


		if(!$config['memcache_port'])

		if(!$config['memcache_port'])

		{

		{

			$config['memcache_port'] = 11211;
}

			$config['memcache_port'] = 11211;
}





		$comment = "";

if(!$db->db_encoding || !$config['db_encoding'])

		$comment = "";

if(!$db->db_encoding || !$config['db_encoding'])

		{

		{

			$comment = " // ";

			$comment = " // ";

		}


		}


		if(!$config['db_encoding'])
{
$config['db_encoding'] = "utf8";
}

$configdata = "<?php

		if(!$config['db_encoding'])
{
$config['db_encoding'] = "utf8";
}

$configdata = "<?php

/**

/**

 * Database configuration
*
* Please see the MyBB Docs for advanced
* database configuration for larger installations

 * Database configuration
*
* Please see the MyBB Docs for advanced
* database configuration for larger installations

 * http://docs.mybb.com/

 * https://docs.mybb.com/

 */

 */





\$config['database']['type'] = '{$config['dbtype']}';
\$config['database']['database'] = '{$config['database']}';
\$config['database']['table_prefix'] = '{$config['table_prefix']}';

\$config['database']['type'] = '{$config['dbtype']}';
\$config['database']['database'] = '{$config['database']}';
\$config['database']['table_prefix'] = '{$config['table_prefix']}';





\$config['database']['hostname'] = '{$config['hostname']}';
\$config['database']['username'] = '{$config['username']}';
\$config['database']['password'] = '{$config['password']}';

\$config['database']['hostname'] = '{$config['hostname']}';
\$config['database']['username'] = '{$config['username']}';
\$config['database']['password'] = '{$config['password']}';


/**


/**

 * Admin CP directory
* For security reasons, it is recommended you
* rename your Admin CP directory. You then need
* to adjust the value below to point to the
* new directory.

 * Admin CP directory
* For security reasons, it is recommended you
* rename your Admin CP directory. You then need
* to adjust the value below to point to the
* new directory.

 */

\$config['admin_dir'] = '{$config['admin_dir']}';

/**

 */

\$config['admin_dir'] = '{$config['admin_dir']}';

/**

 * Hide all Admin CP links
* If you wish to hide all Admin CP links
* on the front end of the board after
* renaming your Admin CP directory, set this
* to 1.

 * Hide all Admin CP links
* If you wish to hide all Admin CP links
* on the front end of the board after
* renaming your Admin CP directory, set this
* to 1.

 */


 */


\$config['hide_admin_links'] = {$config['hide_admin_links']};

/**

\$config['hide_admin_links'] = {$config['hide_admin_links']};

/**

Zeile 1381Zeile 1384
 *
* If you wish to use the file system (cache/ directory)
* you can change the value below to 'files', 'memcache' or 'eaccelerator' from 'db'.

 *
* If you wish to use the file system (cache/ directory)
* you can change the value below to 'files', 'memcache' or 'eaccelerator' from 'db'.

 */


 */


\$config['cache_store'] = '{$config['cache_store']}';

/**

\$config['cache_store'] = '{$config['cache_store']}';

/**

Zeile 1392Zeile 1395
 *  of your memcache server below.
*
* If not using memcache, ignore this section.

 *  of your memcache server below.
*
* If not using memcache, ignore this section.

 */


 */


\$config['memcache_host'] = '{$config['memcache_host']}';
\$config['memcache_port'] = {$config['memcache_port']};


\$config['memcache_host'] = '{$config['memcache_host']}';
\$config['memcache_port'] = {$config['memcache_port']};


Zeile 1403Zeile 1406
 *  be edited, deleted or banned in the Admin CP.
* The administrator permissions for these users
* cannot be altered either.

 *  be edited, deleted or banned in the Admin CP.
* The administrator permissions for these users
* cannot be altered either.

 */

\$config['super_admins'] = '{$config['super_admins']}';

 */

\$config['super_admins'] = '{$config['super_admins']}';


/**
* Database Encoding


/**
* Database Encoding

Zeile 1413Zeile 1416
 *  the line below (if it isn't already) and change
* the current value to the mysql charset:
* http://dev.mysql.com/doc/refman/5.1/en/charset-mysql.html

 *  the line below (if it isn't already) and change
* the current value to the mysql charset:
* http://dev.mysql.com/doc/refman/5.1/en/charset-mysql.html

 */


 */


{$comment}\$config['database']['encoding'] = '{$config['db_encoding']}';

/**

{$comment}\$config['database']['encoding'] = '{$config['db_encoding']}';

/**

Zeile 1425Zeile 1428
 *  the number of days before each log should be pruned.
* If you set the value to 0, the logs will not be pruned.
*/

 *  the number of days before each log should be pruned.
* If you set the value to 0, the logs will not be pruned.
*/





\$config['log_pruning'] = array(
'admin_logs' => 365, // Administrator logs
'mod_logs' => 0, // Moderator logs

\$config['log_pruning'] = array(
'admin_logs' => 365, // Administrator logs
'mod_logs' => 0, // Moderator logs

Zeile 1443Zeile 1446
	echo "<p>Click next to continue with the upgrade process.</p>";

global $footer_extra;

	echo "<p>Click next to continue with the upgrade process.</p>";

global $footer_extra;

	$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer("12_dbchanges6");
}

function upgrade12_dbchanges6()


$output->print_footer("12_dbchanges6");
}

function upgrade12_dbchanges6()

{
global $db, $output;

$output->print_header("Post IP Conversion");

if(!$_POST['ipspage'])
{
$ipp = 5000;
}
else
{
$ipp = $_POST['ipspage'];
}


{
global $db, $output;

$output->print_header("Post IP Conversion");

if(!$_POST['ipspage'])
{
$ipp = 5000;
}
else
{
$ipp = (int)$_POST['ipspage'];
}


	if($_POST['ipstart'])
{

	if($_POST['ipstart'])
{

		$startat = $_POST['ipstart'];

		$startat = (int)$_POST['ipstart'];

		$upper = $startat+$ipp;
$lower = $startat;
}

		$upper = $startat+$ipp;
$lower = $startat;
}

Zeile 1515Zeile 1518
	$output->print_contents($contents);

global $footer_extra;

	$output->print_contents($contents);

global $footer_extra;

	$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer($nextact);
}


$output->print_footer($nextact);
}

Zeile 1532Zeile 1535
	}
else
{

	}
else
{

		$ipp = $_POST['ipspage'];

		$ipp = (int)$_POST['ipspage'];

	}

if($_POST['ipstart'])
{

	}

if($_POST['ipstart'])
{

		$startat = $_POST['ipstart'];

		$startat = (int)$_POST['ipstart'];

		$upper = $startat+$ipp;
$lower = $startat;
}

		$upper = $startat+$ipp;
$lower = $startat;
}

Zeile 1599Zeile 1602
	$output->print_contents($contents);

global $footer_extra;

	$output->print_contents($contents);

global $footer_extra;

	$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer($nextact);
}


$output->print_footer($nextact);
}

Zeile 1616Zeile 1619
	}
else
{

	}
else
{

		$epp = $_POST['eventspage'];

		$epp = (int)$_POST['eventspage'];

	}

if($_POST['eventstart'])
{

	}

if($_POST['eventstart'])
{

		$startat = $_POST['eventstart'];

		$startat = (int)$_POST['eventstart'];

		$upper = $startat+$epp;
$lower = $startat;
}

		$upper = $startat+$epp;
$lower = $startat;
}

Zeile 1664Zeile 1667
		}

if($db->field_exists('starttime', "events"))

		}

if($db->field_exists('starttime', "events"))

		{

		{

			$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP starttime;");

			$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP starttime;");

		}

		}


if($db->field_exists('endtime', "events"))


if($db->field_exists('endtime', "events"))

		{

		{

			$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP endtime;");

			$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP endtime;");

		}


		}


		if($db->field_exists('timezone', "events"))
{
$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP timezone;");

		if($db->field_exists('timezone', "events"))
{
$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP timezone;");

		}


		}


		if($db->field_exists('ignoretimezone', "events"))

		if($db->field_exists('ignoretimezone', "events"))

		{

		{

			$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP ignoretimezone;");

			$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP ignoretimezone;");

		}


		}


		if($db->field_exists('usingtime', "events"))
{
$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP usingtime;");
}

if($db->field_exists('repeats', "events"))

		if($db->field_exists('usingtime', "events"))
{
$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP usingtime;");
}

if($db->field_exists('repeats', "events"))

		{

		{

			$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP repeats;");
}


			$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP repeats;");
}


Zeile 1737Zeile 1740
		}

$date = true;

		}

$date = true;

	}
else

	}
else

	{
$date = false;
}

	{
$date = false;
}

Zeile 1750Zeile 1753
		$nextact = "12_dbchanges8";
$startat = $startat+$epp;
$contents .= "<p><input type=\"hidden\" name=\"eventspage\" value=\"$epp\" /><input type=\"hidden\" name=\"eventstart\" value=\"$startat\" />Done. Click Next to move on to the next set of events.</p>";

		$nextact = "12_dbchanges8";
$startat = $startat+$epp;
$contents .= "<p><input type=\"hidden\" name=\"eventspage\" value=\"$epp\" /><input type=\"hidden\" name=\"eventstart\" value=\"$startat\" />Done. Click Next to move on to the next set of events.</p>";

	}

	}

	else
{
$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP donecon");

	else
{
$db->write_query("ALTER TABLE ".TABLE_PREFIX."events DROP donecon");

Zeile 1763Zeile 1766
	}
$output->print_contents($contents);


	}
$output->print_contents($contents);


	global $footer_extra;
$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


	global $footer_extra;
$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


	$output->print_footer($nextact);
}

	$output->print_footer($nextact);
}





function upgrade12_redothemes()
{
global $db, $output, $config, $mybb;

function upgrade12_redothemes()
{
global $db, $output, $config, $mybb;





	$output->print_header("Converting themes");

if(!@is_dir(MYBB_ROOT.'cache/'))

	$output->print_header("Converting themes");

if(!@is_dir(MYBB_ROOT.'cache/'))

	{

	{

		@mkdir(MYBB_ROOT.'cache/', 077);

// Add in empty index.html!
$fp = @fopen(MYBB_ROOT."cache/index.html", "w");
@fwrite($fp, "");
@fclose($fp);

		@mkdir(MYBB_ROOT.'cache/', 077);

// Add in empty index.html!
$fp = @fopen(MYBB_ROOT."cache/index.html", "w");
@fwrite($fp, "");
@fclose($fp);

	}

	}

	$cachewritable = @fopen(MYBB_ROOT.'cache/test.write', 'w');
if(!$cachewritable)

	$cachewritable = @fopen(MYBB_ROOT.'cache/test.write', 'w');
if(!$cachewritable)

	{

	{

		$not_writable = true;

		$not_writable = true;

		@fclose($cachewritable);
}
else
{

	}
else
{


		@fclose($cachewritable);
@my_chmod(MYBB_ROOT.'cache', '0777');
@my_chmod(MYBB_ROOT.'cache/test.write', '0777');

		@fclose($cachewritable);
@my_chmod(MYBB_ROOT.'cache', '0777');
@my_chmod(MYBB_ROOT.'cache/test.write', '0777');

Zeile 1819Zeile 1821
	if(!$themewritable)
{
$not_writable = true;

	if(!$themewritable)
{
$not_writable = true;

		@fclose($themewritable);

 
	}
else
{

	}
else
{

Zeile 1861Zeile 1862
	{
$db->drop_table("themestylesheets");
}

	{
$db->drop_table("themestylesheets");
}

 

$collation = $db->build_create_table_collation();


$db->write_query("CREATE TABLE ".TABLE_PREFIX."themestylesheets(
sid int unsigned NOT NULL auto_increment,


$db->write_query("CREATE TABLE ".TABLE_PREFIX."themestylesheets(
sid int unsigned NOT NULL auto_increment,

Zeile 1986Zeile 1989
	echo "<p>Click next to continue with the upgrade process.</p>";

global $footer_extra;

	echo "<p>Click next to continue with the upgrade process.</p>";

global $footer_extra;

	//$footer_extra = "<script type=\"text/javascript\">$(document).ready(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";

	//$footer_extra = "<script type=\"text/javascript\">$(function() { var button = $('.submit_button'); if(button) { button.val('Automatically Redirecting...'); button.prop('disabled', true); button.css('color', '#aaa'); button.css('border-color', '#aaa'); document.forms[0].submit(); } });</script>";


$output->print_footer("12_done");
}


$output->print_footer("12_done");
}