Function Hook_search_quiz->run

Definitions

sources/hooks/modules/search/quiz.php

  • Run function for search results.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Return: array

Parameters

Name Type Default Set Range Description
$search_query string required parameter N/A N/A Search query
$content_where string required parameter N/A N/A WHERE clause that selects the content according to the search query; passed in addition to $search_query to avoid unnecessary reparsing. ? refers to the yet-unknown field name (blank: full-text search)
$where_clause string required parameter N/A N/A Initial WHERE clause that already takes $search_under into account (should be nothing else unless it is guaranteed hook will use the global get_search_rows function)
$search_under string required parameter N/A N/A Comma-separated list of categories to search under
$only_search_meta boolean required parameter N/A N/A Whether to only do a META (tags) search
$only_titles boolean required parameter N/A N/A Whether only to search titles (as opposed to both titles and content)
$max integer required parameter N/A N/A Start position in total results
$start integer required parameter N/A N/A Maximum results to return in total
$sort string required parameter N/A N/A The sort type (gets remapped to a field in this function)
$direction ID_TEXT required parameter N/A N/A Order direction
$author SHORT_TEXT required parameter N/A N/A Username/Author to match for
$author_id ?MEMBER required parameter N/A N/A Member-ID to match for (null: unknown)
$cutoff mixed required parameter N/A N/A Cutoff date (TIME or a pair representing the range or null)

Return

  • List of maps (template, orderer)
  • Type: array
  • Set: N/A
  • Range: N/A