X-Git-Url: https://git.cyclocoop.org/?a=blobdiff_plain;f=includes%2Fwidget%2Fsearch%2FFullSearchResultWidget.php;h=af1e02754c8b91f385b64f635714eb617ea11463;hb=19c45cdb1690fc0c545236e535c245c37864afdd;hp=0d0fa124110050b8c63033b537aa2cb1d0b6d5a3;hpb=2c8f7978df47f338ee6e245e3efba6175ba425e9;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/widget/search/FullSearchResultWidget.php b/includes/widget/search/FullSearchResultWidget.php index 0d0fa12411..af1e02754c 100644 --- a/includes/widget/search/FullSearchResultWidget.php +++ b/includes/widget/search/FullSearchResultWidget.php @@ -79,7 +79,7 @@ class FullSearchResultWidget implements SearchResultWidget { if ( !Hooks::run( 'ShowSearchHit', [ $this->specialPage, $result, $terms, &$link, &$redirect, &$section, &$extract, - &$score, &$size, &$date, &$related, &$html + &$score, &$desc, &$date, &$related, &$html ] ) ) { return $html; } @@ -133,13 +133,14 @@ class FullSearchResultWidget implements SearchResultWidget { $title = clone $result->getTitle(); $query = []; + $attributes = [ 'data-serp-pos' => $position ]; Hooks::run( 'ShowSearchHitTitle', - [ &$title, &$snippet, $result, $terms, $this->specialPage, &$query ] ); + [ &$title, &$snippet, $result, $terms, $this->specialPage, &$query, &$attributes ] ); $link = $this->linkRenderer->makeLink( $title, $snippet, - [ 'data-serp-pos' => $position ], + $attributes, $query ); @@ -162,7 +163,7 @@ class FullSearchResultWidget implements SearchResultWidget { : $this->linkRenderer->makeLink( $title, $text ? new HtmlArmor( $text ) : null ); return "" . - $this->specialPage->msg( $msgKey )->rawParams( $inner )->text() + $this->specialPage->msg( $msgKey )->rawParams( $inner )->parse() . ""; }