/**
  * Past straight to results, display and encode the query.
  */
 public function getSearchResults()
 {
     $query = $this->getSearchQuery();
     $search = new DocumentationSearch();
     $search->setQuery($query);
     $search->setVersions($this->getSearchedVersions());
     $search->setModules($this->getSearchedEntities());
     $search->setOutputController($this->owner);
     return $search->renderResults();
 }
 /**
  * Performs the search against the documentation in the system
  * @param {string} $keywords Keywords to search for
  * @param {int} $startIndex Start index for pagination
  * @return {ArrayData} Array Data of information about the results
  * 
  * @see ICMSUserDocsSearchEngine::getSearchResults()
  */
 public function getSearchResults($keywords, $startIndex = 0, SS_HTTPRequest $request = null)
 {
     //Workaround to set the search index location
     Config::inst()->update('DocumentationSearch', 'index_location', self::config()->index_location);
     //Search the index
     $search = new DocumentationSearch();
     $search->setQuery($keywords);
     $search->setVersions(array());
     $search->setModules(array());
     $search->performSearch();
     return $search->getSearchResults($request);
 }