Search-Group
Search groups can be used to filter Search-Entries.
Groups
Groups give you the possibility of limiting the possible results.
If you want to make a search just for your employees-page that searches through your employees,
you can put the group "employee" on the Search-Entry.
Through the group attribute you have the opportunity to delimit what a Search-Input can find. If a search Input doesn't have a group however, all Search-Entries can be found, also the ones that have group defined.
Employee-Search
Here is an example of how a Search-Group can be used.
<div> <h3>Search Employees here:</h3> <?php $searchHtml->input(array('employee')) ?> </div> <h3>Found Employees:</h3> <?php $searchHtml->resultOpen(array('employee')) ?> <div class="employee-result-header"> <h5>Employees found:</h5> <?php $searchHtml->getResultNum() ?> </div> <?php $searchHtml->resultContent() ?> <?php $searchHtml->resultClose() ?>
Notice that the parameter array('employee') is used to mark the groups that want to be used. As this parameter is an array, you can mark multiple Search-Groups to be found.