You are here

public function SearchApiSpellcheckSuggestionLink::createQuery in Search API Spellcheck 7

Sets the property 'query' to the current query plus the suggested string.

If the search key is stored in a field in the query string then this field is updated with the suggested string.

1 call to SearchApiSpellcheckSuggestionLink::createQuery()
SearchApiSpellcheckSuggestionLink::__construct in includes/SearchApiSpellcheckSuggestionLink.inc
Constructor.

File

includes/SearchApiSpellcheckSuggestionLink.inc, line 61
The class is a helpful way to provide both an updated search query link and access to all the link components for themers.

Class

SearchApiSpellcheckSuggestionLink
@file The class is a helpful way to provide both an updated search query link and access to all the link components for themers.

Code

public function createQuery() {
  $query = drupal_get_query_parameters();
  if ($this->method == 'get') {
    $query[$this->method_key] = $this->suggestion;
  }
  $this->query = $query;
}