public function OnPageInit() { if (isset($_GET['q']) and $_GET['q']) { require_once "search/search-query.class.php"; $this->query = new SearchQuery($_GET['q']); require_once 'data/paged-results.class.php'; $this->paging = new PagedResults(); $this->paging->SetPageSize(20); $this->paging->SetResultsTextSingular('result'); $this->paging->SetResultsTextPlural('results'); $this->query->SetFirstResult($this->paging->GetFirstResultOnPage()); $this->query->SetPageSize($this->paging->GetPageSize()); } }