* Removed some backtracking regexes with an O(N^2) worst case, replaced with StringUtils::delimiterReplace(). There is a beneficial functional difference: /*/ is no longer considered to be a complete CSS comment. * Changed the parser strip state from an array to an object. This should hopefully avoid the PHP bugs with array references. StripState uses the new ReplacementArray to do the replacements, thereby supporting FSS. * Removed DatabaseFunctions.php from the default startup sequence. Moved wfGetDB() to GlobalFunctions.php. * Introduced the SiteStats class, with a collection of cached site stats accessor functions. * Removed all global functions from Parser.php, they don't belong there. * Made LanguageConverter use the new ReplacementArray class instead of managing its own FSS objects.
14 lines
374 B
PHP
14 lines
374 B
PHP
<?php
|
|
#
|
|
# Print SQL to insert namespace names into database.
|
|
# This source code is in the public domain.
|
|
|
|
require_once( "commandLine.inc" );
|
|
|
|
for ($i = -2; $i < 16; ++$i) {
|
|
$nsname = mysql_escape_string( $wgLang->getNsText( $i ) );
|
|
$dbname = mysql_escape_string( $wgDBname );
|
|
print "INSERT INTO ns_name(ns_db, ns_num, ns_name) VALUES('$dbname', $i, '$nsname');\n";
|
|
}
|
|
|
|
?>
|