X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fwidget%2Fsearch%2FSearchFormWidget.php;h=a7407a062fcdf06c857e5bd85bbab5533204bb5b;hb=659864b8ad7c23362426206c0993af8a3317d9ee;hp=145184309336927f6881c640d1cb73eafeb348c6;hpb=2ece47c5c9a5869d0e8996b64632e4d752ca9a52;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/widget/search/SearchFormWidget.php b/includes/widget/search/SearchFormWidget.php index 1451843093..a7407a062f 100644 --- a/includes/widget/search/SearchFormWidget.php +++ b/includes/widget/search/SearchFormWidget.php @@ -79,6 +79,8 @@ class SearchFormWidget { * @return string HTML */ protected function shortDialogHtml( $profile, $term, $numResults, $totalResults, $offset ) { + $html = ''; + $searchWidget = new SearchInputWidget( [ 'id' => 'searchText', 'name' => 'search', @@ -96,11 +98,7 @@ class SearchFormWidget { 'align' => 'top', ] ); - $html = - Html::hidden( 'title', $this->specialSearch->getPageTitle()->getPrefixedText() ) . - Html::hidden( 'profile', $profile ) . - Html::hidden( 'fulltext', '1' ) . - $layout; + $html .= $layout; if ( $totalResults > 0 && $offset < $totalResults ) { $html .= Xml::tags( @@ -113,6 +111,11 @@ class SearchFormWidget { ); } + $html .= + Html::hidden( 'title', $this->specialSearch->getPageTitle()->getPrefixedText() ) . + Html::hidden( 'profile', $profile ) . + Html::hidden( 'fulltext', '1' ); + return $html; } @@ -203,16 +206,13 @@ class SearchFormWidget { */ protected function optionsHtml( $term, $isPowerSearch, $profile ) { $html = ''; - $opts = [ - 'profile' => $profile, - ]; if ( $isPowerSearch ) { - $html .= $this->powerSearchBox( $term, $opts ); + $html .= $this->powerSearchBox( $term, [] ); } else { $form = ''; Hooks::run( 'SpecialSearchProfileForm', [ - $this->specialSearch, &$form, $profile, $term, $opts + $this->specialSearch, &$form, $profile, $term, [] ] ); $html .= $form; }