Defines a table which can be searched against using the front-end search
This is the code documentation for the SproutCMS project
Search documentation |
class SearchHandlerDefines a table which can be searched against using the front-end search
Extending this class<?php /** * New class description goes here * * @author Your Name, 2024-11-25 **/ class NewClassName extends SearchHandler { /** * Gets all having clauses which should be added to the search query **/ public function getHaving () { // Method code goes here } public function __construct (string $table, string $ctlr_name) { // Method code goes here } /** * Gets the table name for the keywords table, e.g. page_keywords **/ public function getTable () { // Method code goes here } /** * Gets the table name for the main table, e.g. pages **/ public function getMainTable () { // Method code goes here } /** * Sets the table name for the keywords table, e.g. page_keywords **/ public function setTable ($val) { // Method code goes here } /** * Gets the controller name, e.g. PageController **/ public function getCtlrName () { // Method code goes here } /** * Sets the controller name, e.g. PageController. The specified controller must implement the FrontEndSearch interface. **/ public function setCtlrName ($val) { // Method code goes here } /** * Gets all where clauses which should be added to the search query **/ public function getWhere () { // Method code goes here } /** * Adds a where clause to this search handler. * Where clauses should refer to the main table using the alias 'main' * e.g. $handler->addWhere("main.active = 1") **/ public function addWhere ($val) { // Method code goes here } /** * Adds a having clause to this search handler. * Having clauses should refer to the main table using the alias 'main' * e.g. $handler->addHaving("main.active = 1") **/ public function addHaving ($val) { // Method code goes here } /** * Gets all joins which should be added to the search query **/ public function getJoins () { // Method code goes here } /** * Adds a join to this search handler. * Inner joins should refer to the main table using the alias 'main' * e.g. $handler->addJoin("INNER JOIN categories ON categories.item_id = main.id") **/ public function addJoin ($val) { // Method code goes here } } ?> |
Powered by Pelzini, version 0.9.0 |
Documentation is made available under the
GNU Free Documentation License 1.2. Generated: Monday, 3rd April, 2023 at 02:59 pm |