(really hating this discussion system)
Setting $wgFavoritesPersonalURL = true;
messes up the keys of the other links, so I copied some code from Extension:AdminLinks to fix that.
Find:
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;
}
Replace with:
//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];
}
}