Stud.IP
2.0 Revision 48548
|
Public Member Functions | |
__construct ($resultstyle= 'name') | |
getTitle () | |
getResults ($keyword, $contextual_data=array(), $limit=PHP_INT_MAX, $offset=0) | |
includePath () | |
Public Member Functions inherited from SearchType | |
getAvatar ($id) | |
getAvatarImageTag ($id) |
__construct | ( | $resultstyle = 'name' | ) |
getResults | ( | $keyword, | |
$contextual_data = array() , |
|||
$limit = PHP_INT_MAX , |
|||
$offset = 0 |
|||
) |
Returns the results to a given keyword. To get the results is the job of this routine and it does not even need to come from a database. The results should be an array in the form array ( array($key, $name), array($key, $name), ... ) where $key is an identifier like user_id and $name is a displayed text that should appear to represent that ID.
keyword,: | string | |
array | $contextual_data | an associative array with more variables |
int | $limit | maximum number of results (default: all) |
int | $offset | return results starting from this row (default: 0) |
Reimplemented from SearchType.
getTitle | ( | ) |
title of the search like "search for courses" or just "courses"
Reimplemented from SearchType.
includePath | ( | ) |
Returns the path to this file, so that this class can be autoloaded and is always available when necessary. Should be: "return <strong>file</strong>;"
Reimplemented from SearchType.