From: Aryeh Gregor Date: Wed, 26 Aug 2009 14:34:28 +0000 (+0000) Subject: For search, move "create page" below "no results" X-Git-Tag: 1.31.0-rc.0~40054 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/exercices/modifier.php?a=commitdiff_plain;h=331664c45265d1eee0f99e464821b5ed6ec08f71;p=lhc%2Fweb%2Fwiklou.git For search, move "create page" below "no results" This looks slightly less odd, with the user no longer being told to create the page before they're even told it doesn't exist. But it still looks pretty odd. --- diff --git a/includes/specials/SpecialSearch.php b/includes/specials/SpecialSearch.php index abe645b348..dfdd25d033 100644 --- a/includes/specials/SpecialSearch.php +++ b/includes/specials/SpecialSearch.php @@ -258,18 +258,6 @@ class SpecialSearch { $wgOut->addHtml( Xml::closeElement( 'form' ) ); $wgOut->addHtml( "
" ); - - // show direct page/create link - if( !is_null($t) ) { - if( !$t->exists() ) { - $wgOut->addWikiMsg( 'searchmenu-new', wfEscapeWikiText( $t->getPrefixedText() ) ); - } else { - $wgOut->addWikiMsg( 'searchmenu-exists', wfEscapeWikiText( $t->getPrefixedText() ) ); - } - } else { - // preserve the paragraph for margins etc... - $wgOut->addHTML('

'); - } // prev/next links if( $num || $this->offset ) { @@ -314,6 +302,18 @@ class SpecialSearch { if( $num === 0 ) { $wgOut->addWikiMsg( 'search-nonefound', wfEscapeWikiText( $term ) ); } + + // show direct page/create link + if( !is_null($t) ) { + if( !$t->exists() ) { + $wgOut->addWikiMsg( 'searchmenu-new', wfEscapeWikiText( $t->getPrefixedText() ) ); + } else { + $wgOut->addWikiMsg( 'searchmenu-exists', wfEscapeWikiText( $t->getPrefixedText() ) ); + } + } else { + // preserve the paragraph for margins etc... + $wgOut->addHTML('

'); + } $wgOut->addHtml( "
" ); if( $num === 0 ) { $wgOut->addHTML( $this->searchFocus() );