DokuWiki

It's better when it's simple

User Tools

Site Tools


devel:event:search_result_fullpage

SEARCH_RESULT_FULLPAGE

Description:
Adjust how a fullpage search result is displayed
Preventable:
No
Added:
2018-04-05

This event is signalled by getFulltextResultsHTML() in inc/Ui/Search.php for every fulltext search result, that is displayed. Handlers can use the BEFORE event to add more information to the result remove existing elements. The AFTER event is not called.

Passed Data

  • $data['resultHeader'] ⇒ Array of strings which will be concatenated and inserted between the <dt></dt> tags of a search result, forming its header.
  • $data['resultBody'] ⇒ Associative array of strings which will be concatenated, wrapped in <dd></dd> tags (with the array key as class) and inserted after the above mentioned <dt></dt> tags, forming the search result's body.
    • Initially there will be the key meta with the last modified data and (optionally) the number of hits and for the first 15 results there will be the snippet key with the snippet
  • $data['page'] ⇒ ID of the page
  • $data['position'] ⇒ Position of the search result

See also

devel/event/search_result_fullpage.txt · Last modified: 2018-12-08 16:03 by torpedo

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki