Vergleich install/index.php - 1.8.11 - 1.8.23

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 56Zeile 56
require_once MYBB_ROOT.'inc/functions_user.php';
require_once MYBB_ROOT.'inc/class_language.php';
$lang = new MyLanguage();

require_once MYBB_ROOT.'inc/functions_user.php';
require_once MYBB_ROOT.'inc/class_language.php';
$lang = new MyLanguage();

$lang->set_path(MYBB_ROOT.'install/resources');

$lang->set_path(INSTALL_ROOT.'resources');

$lang->load('language');

// Load DB interface

$lang->load('language');

// Load DB interface

Zeile 106Zeile 106
		'title' => 'PostgreSQL',
'short_title' => 'PostgreSQL',
'structure_file' => 'pgsql_db_tables.php',

		'title' => 'PostgreSQL',
'short_title' => 'PostgreSQL',
'structure_file' => 'pgsql_db_tables.php',

		'population_file' => 'mysql_db_inserts.php'

		'population_file' => 'pgsql_db_inserts.php'

	);
}


	);
}


Zeile 120Zeile 120
			'title' => 'SQLite 3',
'short_title' => 'SQLite',
'structure_file' => 'sqlite_db_tables.php',

			'title' => 'SQLite 3',
'short_title' => 'SQLite',
'structure_file' => 'sqlite_db_tables.php',

			'population_file' => 'mysql_db_inserts.php'

			'population_file' => 'pgsql_db_inserts.php'

		);
}
}

		);
}
}

Zeile 463Zeile 463
modification follow.

TERMS AND CONDITIONS

modification follow.

TERMS AND CONDITIONS





  0. Definitions.

"This License" refers to version 3 of the GNU General Public License.

  0. Definitions.

"This License" refers to version 3 of the GNU General Public License.

Zeile 508Zeile 508
  The "source code" for a work means the preferred form of the work
for making modifications to it. "Object code" means any non-source
form of a work.

  The "source code" for a work means the preferred form of the work
for making modifications to it. "Object code" means any non-source
form of a work.





  A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that

  A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that

Zeile 598Zeile 598

You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.


You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.





  5. Conveying Modified Source Versions.

You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these conditions:

  5. Conveying Modified Source Versions.

You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these conditions:





    a) The work must carry prominent notices stating that you modified
it, and giving a relevant date.

    a) The work must carry prominent notices stating that you modified
it, and giving a relevant date.





    b) The work must carry prominent notices stating that it is
released under this License and any conditions added under section
7. This requirement modifies the requirement in section 4 to

    b) The work must carry prominent notices stating that it is
released under this License and any conditions added under section
7. This requirement modifies the requirement in section 4 to

Zeile 620Zeile 620
    regardless of how they are packaged.  This License gives no
permission to license the work in any other way, but it does not
invalidate such permission if you have separately received it.

    regardless of how they are packaged.  This License gives no
permission to license the work in any other way, but it does not
invalidate such permission if you have separately received it.





    d) If the work has interactive user interfaces, each must display
Appropriate Legal Notices; however, if the Program has interactive
interfaces that do not display Appropriate Legal Notices, your

    d) If the work has interactive user interfaces, each must display
Appropriate Legal Notices; however, if the Program has interactive
interfaces that do not display Appropriate Legal Notices, your

Zeile 642Zeile 642
of sections 4 and 5, provided that you also convey the
machine-readable Corresponding Source under the terms of this License,
in one of these ways:

of sections 4 and 5, provided that you also convey the
machine-readable Corresponding Source under the terms of this License,
in one of these ways:





    a) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by the
Corresponding Source fixed on a durable physical medium

    a) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by the
Corresponding Source fixed on a durable physical medium

Zeile 1443Zeile 1443
	$connection = $db->connect($connect_array);
if($connection === false)
{

	$connection = $db->connect($connect_array);
if($connection === false)
{

		$errors[] = $lang->sprintf($lang->db_step_error_noconnect, $config['dbhost']);

		$errors[] = $lang->sprintf($lang->db_step_error_noconnect, htmlspecialchars_uni($config['dbhost']));

	}
// double check if the DB exists for MySQL
elseif(method_exists($db, 'select_db') && !$db->select_db($config['dbname']))
{

	}
// double check if the DB exists for MySQL
elseif(method_exists($db, 'select_db') && !$db->select_db($config['dbname']))
{

		$errors[] = $lang->sprintf($lang->db_step_error_nodbname, $config['dbname']);

		$errors[] = $lang->sprintf($lang->db_step_error_nodbname, htmlspecialchars_uni($config['dbname']));

	}

// Most DB engines only allow certain characters in the table name. Oracle requires an alphabetic character first.

	}

// Most DB engines only allow certain characters in the table name. Oracle requires an alphabetic character first.

Zeile 1477Zeile 1477
	// Decide if we can use a database encoding or not
if($db->fetch_db_charsets() != false)
{

	// Decide if we can use a database encoding or not
if($db->fetch_db_charsets() != false)
{

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

		$db_encoding = "\$config['database']['encoding'] = '".addcslashes($config['encoding'], "'")."';";

	}
else
{

	}
else
{

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

		$db_encoding = "// \$config['database']['encoding'] = '".addcslashes($config['encoding'], "'")."';";

	}

	}


$config['dbpass'] = addslashes($config['dbpass']);

 

// Write the configuration file
$configdata = "<?php


// Write the configuration file
$configdata = "<?php

Zeile 1494Zeile 1492
 * Please see the MyBB Docs for advanced
* database configuration for larger installations
* https://docs.mybb.com/

 * Please see the MyBB Docs for advanced
* database configuration for larger installations
* https://docs.mybb.com/

 */

\$config['database']['type'] = '{$mybb->input['dbengine']}';
\$config['database']['database'] = '{$config['dbname']}';
\$config['database']['table_prefix'] = '{$config['tableprefix']}';

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

/**

 */

\$config['database']['type'] = '".addcslashes($mybb->input['dbengine'], "'")."';
\$config['database']['database'] = '".addcslashes($config['dbname'], "'")."';
\$config['database']['table_prefix'] = '".addcslashes($config['tableprefix'], "'")."';

\$config['database']['hostname'] = '".addcslashes($config['dbhost'], "'")."';
\$config['database']['username'] = '".addcslashes($config['dbuser'], "'")."';
\$config['database']['password'] = '".addcslashes($config['dbpass'], "'")."';

/**

 * 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'] = 'admin';

/**

\$config['admin_dir'] = 'admin';

/**

Zeile 1520Zeile 1518
 *  on the front end of the board after
* renaming your Admin CP directory, set this
* to 1.

 *  on the front end of the board after
* renaming your Admin CP directory, set this
* to 1.

 */

\$config['hide_admin_links'] = 0;

/**

 */

\$config['hide_admin_links'] = 0;

/**

 * Data-cache configuration
* The data cache is a temporary cache
* of the most commonly accessed data in MyBB.
* By default, the database is used to store this data.

 * Data-cache configuration
* The data cache is a temporary cache
* of the most commonly accessed data in MyBB.
* By default, the database is used to store this data.

 *
* If you wish to use the file system (cache/ directory), MemCache (or MemCached), xcache, APC, or eAccelerator
* you can change the value below to 'files', 'memcache', 'memcached', 'xcache', 'apc' or 'eaccelerator' from 'db'.
*/


 *
* If you wish to use the file system (cache/ directory), MemCache (or MemCached), xcache, APC, APCu, eAccelerator or Redis
* you can change the value below to 'files', 'memcache', 'memcached', 'xcache', 'apc', 'apcu', 'eaccelerator' or 'redis' from 'db'.
*/


\$config['cache_store'] = 'db';

/**

\$config['cache_store'] = 'db';

/**

Zeile 1547Zeile 1545

\$config['memcache']['host'] = 'localhost';
\$config['memcache']['port'] = 11211;


\$config['memcache']['host'] = 'localhost';
\$config['memcache']['port'] = 11211;

 

/**
* Redis configuration
* If you are using Redis as your data-cache
* you need to configure the hostname and port
* of your redis server below. If you want
* to connect via unix sockets, use the full
* path to the unix socket as host and leave
* the port setting unconfigured or false.
*/

\$config['redis']['host'] = 'localhost';
\$config['redis']['port'] = 6379;


/**
* Super Administrators


/**
* Super Administrators

Zeile 1669Zeile 1680
 */
function populate_tables()
{

 */
function populate_tables()
{

	global $output, $lang;

	global $output, $lang, $dboptions;


require MYBB_ROOT.'inc/config.php';
$db = db_connection($config);


require MYBB_ROOT.'inc/config.php';
$db = db_connection($config);

Zeile 2284Zeile 2295
		'lastvisit' => $now,
'website' => '',
'icq' => '',

		'lastvisit' => $now,
'website' => '',
'icq' => '',

		'aim' => '',
'yahoo' => '',

 
		'skype' =>'',
'google' =>'',
'birthday' => '',

		'skype' =>'',
'google' =>'',
'birthday' => '',

Zeile 2317Zeile 2326
		'referrer' => 0,
'buddylist' => '',
'ignorelist' => '',

		'referrer' => 0,
'buddylist' => '',
'ignorelist' => '',

		'pmfolders' => '',

		'pmfolders' => "0**$%%$1**$%%$2**$%%$3**$%%$4**",

		'notepad' => '',
'showredirect' => 1,
'usernotes' => ''

		'notepad' => '',
'showredirect' => 1,
'usernotes' => ''

Zeile 2370Zeile 2379
	// Automatic Login
my_unsetcookie("sid");
my_unsetcookie("mybbuser");

	// Automatic Login
my_unsetcookie("sid");
my_unsetcookie("mybbuser");

	my_setcookie('mybbuser', $uid.'_'.$loginkey, null, true);

	my_setcookie('mybbuser', $uid.'_'.$loginkey, null, true, "lax");

	ob_end_flush();

// Make fulltext columns if supported

	ob_end_flush();

// Make fulltext columns if supported

Zeile 2404Zeile 2413
	$cache->update_posticons();
$cache->update_spiders();
$cache->update_bannedips();

	$cache->update_posticons();
$cache->update_spiders();
$cache->update_bannedips();

	$cache->update_banned();

 
	$cache->update_bannedemails();
$cache->update_birthdays();
$cache->update_groupleaders();

	$cache->update_bannedemails();
$cache->update_birthdays();
$cache->update_groupleaders();

Zeile 2517Zeile 2525
	$query = $db->simple_select('settings', '*', '', array('order_by' => 'title'));
while($setting = $db->fetch_array($query))
{

	$query = $db->simple_select('settings', '*', '', array('order_by' => 'title'));
while($setting = $db->fetch_array($query))
{

		$setting['value'] = str_replace("\"", "\\\"", $setting['value']);


		$setting['name'] = addcslashes($setting['name'], "\\'");
$setting['value'] = addcslashes($setting['value'], '\\"$');

		$settings .= "\$settings['{$setting['name']}'] = \"{$setting['value']}\";\n";
}
if(!empty($settings))

		$settings .= "\$settings['{$setting['name']}'] = \"{$setting['value']}\";\n";
}
if(!empty($settings))