Bugfixes/MediaWiki 1.25
< Bugfixes
| tbd @ |
|---|
MW 1.25.2
Extension:MultiBoilerplate (2.1.0)
- Feature by Orci, MultiBoilerplate.hooks.php
| search | replace |
|---|---|
$editPage->textbox1 = $content;
|
$content = preg_replace( '#<pre>(.*?)</pre>#ims', '$1', $content );
$content = preg_replace( '#<nowiki>(.*?)</nowiki>#ims', '$1', $content );
$editPage->textbox1 = $content;
|
- Bugfix by Stip, MultiBoilerplate.hooks.php
- (enables defining boilerplates via MediaWiki:Multiboilerplate if there are none defined in localsettings)
| search | replace |
|---|---|
if ( is_array( $wgMultiBoilerplateOptions ) ) {
|
if ( !empty( $wgMultiBoilerplateOptions ) ) {
|
- Bugfix by Stip, SpecialBoilerplates.php
- (boilerplates defined on MediaWiki:Multiboilerplate will be shown on Spezial:Verfügbare Textvorlagen (Special:Boilerplates) if no boilerplates are defined in localsettings)
| search | replace |
|---|---|
if ( is_array( $wgMultiBoilerplateOptions ) ) {
|
if ( !empty( $wgMultiBoilerplateOptions ) ) {
|
$things = explode( "\n", str_replace( "\r", "\n", str_replace(
"\r\n", "\n", wfMessage( 'multiboilerplate' )
) ) ); // Ensure line-endings are \n
|
$things = wfMessage( 'multiboilerplate' )->inContentLanguage()->text();
$things = explode( "\n", str_replace(
"\r", "\n", str_replace( "\r\n", "\n", $things )
) ); // Ensure line-endings are \n
|
Extension:Favorites (1.1.2)
- Bugfix by Stip based on AdminLinks_body.php of Extension:Admin Links, FavoritesHooks.php
- (inserting link to Special:Favoritelist into personal links no longer changes keys of other links)
| search | replace |
|---|---|
if ( $wgFavoritesPersonalURL && $wgUser->isLoggedIn() ) {
$url['userpage'] = array_shift( $personal_urls );
$url[] = array_shift( $personal_urls );
$url[] = array_shift( $personal_urls );
$url[] = array( 'text' => wfMessage( 'myfavoritelist' )->text(),
'href' => SpecialPage::getTitleFor( 'Favoritelist' )->getLocalURL() );
$personal_urls = $url + $personal_urls;
}
|
//taken from AdminLinks_body.php of the AdminLinks-Extension
if ( $wgFavoritesPersonalURL && $wgUser->isLoggedIn() ) {
$al = SpecialPage::getTitleFor( 'Favoritelist' );
$href = $al->getLocalURL();
$favorites_vals = array(
'text' => wfMessage( 'myfavoritelist' )->text(),
'href' => $href,
'active' => ( $href == $wgTitle->getLocalURL() )
);
// find the location of the 'my preferences' link, and
// add the link to 'AdminLinks' right before it.
// this is a "key-safe" splice - it preserves both the
// keys and the values of the array, by editing them
// separately and then rebuilding the array.
// based on the example at http://us2.php.net/manual/en/function.array-splice.php#31234
$tab_keys = array_keys( $personal_urls );
$tab_values = array_values( $personal_urls );
$watch_location = array_search( 'watchlist', $tab_keys );
array_splice( $tab_keys, $watch_location, 0, 'Favoritelist' );
array_splice( $tab_values, $watch_location, 0, array( $favorites_vals ) );
$personal_urls = array();
for ( $i = 0; $i < count( $tab_keys ); $i++ ) {
$personal_urls[$tab_keys[$i]] = $tab_values[$i];
}
}
|
- Bugfix by Stip, MultiCategorySearch_body.php
- (deprecated methods of calling system messages removed, see deprecated wfMsg* functions and Output modes and escaping)
| search | replace |
|---|---|
wfMsg( 'somekey' )
|
wfMessage( 'somekey' )->escaped()
|
wfMsgHtml( 'somekey' )
|
wfMessage( 'somekey' )->escaped()
|
- Bugfix by Stip, MultiCategorySearch_body.php
- (enables wikitext in MediaWiki:Multicatsearch comment)
| search | replace |
|---|---|
$msgComment = wfMsgHtml( 'multicatsearch_comment' );
|
$msgComment = wfMessage( 'multicatsearch_comment' )->text();
|
Extension:CentralAuth (Version?)
- Bugfix by Stip based on answer by Matt Lord to bug report, central-auth.sql
- (avoids "ERROR 1071 (42000): Specified key was too long; max key length is 1000 bytes")
| search | replace |
|---|---|
CREATE TABLE /*_*/localnames (
ln_wiki varchar(255) binary not null,
ln_name varchar(255) binary not null,
primary key (ln_wiki, ln_name)
) /*$wgDBTableOptions*/;
CREATE INDEX /*i*/ln_name_wiki ON /*_*/localnames (ln_name, ln_wiki);
|
CREATE TABLE /*_*/localnames (
ln_wiki varchar(255) binary not null,
ln_name varchar(255) binary not null,
primary key (ln_wiki(100), ln_name(200))
) /*$wgDBTableOptions*/;
CREATE INDEX /*i*/ln_name_wiki ON /*_*/localnames (ln_name(200), ln_wiki(100));
|
CREATE INDEX /*i*/gu_hidden ON /*_*/globaluser ( gu_name(255), gu_hidden(255) );
|
CREATE INDEX /*i*/gu_hidden ON /*_*/globaluser ( gu_name(255), gu_hidden(100) );
|
primary key (lu_wiki, lu_name)
) /*$wgDBTableOptions*/;
CREATE INDEX /*i*/lu_name_wiki ON /*_*/localuser (lu_name, lu_wiki);
|
primary key (lu_wiki(100), lu_name(200))
) /*$wgDBTableOptions*/;
CREATE INDEX /*i*/lu_name_wiki ON /*_*/localuser (lu_name(200), lu_wiki(100));
|
PRIMARY KEY (ggp_group, ggp_permission)
) /*$wgDBTableOptions*/;
|
PRIMARY KEY (ggp_group(100), ggp_permission(200))
) /*$wgDBTableOptions*/;
|
CREATE UNIQUE INDEX /*i*/ru_oldname ON /*_*/renameuser_status (ru_oldname, ru_wiki);
|
CREATE UNIQUE INDEX /*i*/ru_oldname ON /*_*/renameuser_status (ru_oldname(200), ru_wiki(100));
|
CREATE INDEX /*i*/rq_oldstatus ON /*_*/renameuser_queue (rq_name, rq_wiki, rq_status);
|
CREATE INDEX /*i*/rq_oldstatus ON /*_*/renameuser_queue (rq_name(200), rq_wiki(100), rq_status);
|
CREATE UNIQUE INDEX /*i*/utr_user ON /*_*/users_to_rename (utr_name, utr_wiki);
|
CREATE UNIQUE INDEX /*i*/utr_user ON /*_*/users_to_rename (utr_name(200), utr_wiki(100));
|