Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Example URL (JSON) : https://wsmedia.tlsecure.com/api/json/00000/searchEngine/default/select?q=tuin
Example URL (XML) : https://wsmedia.tlsecure.com/api/XML/00000/searchEngine/default/select?q=tuin

Available services :

  • Select - allows the user to search within the shop's available catalogues

Escaping Special Characters

Solr supports escaping special characters that are part of the query syntax. The current list special characters are

...

Code Block
static function escapeSolrValue($string) {
    $match = array('\\', '+', '-', '&', '|', '!', '(', ')', '{', '}', '[', ']', '^',
     '~', '*', '?', ':', '"', ';', ' ', 'AND', 'OR', 'NOT');
    $replace = array('\\\\', '\\+', '\\-', '\\&', '\\|', '\\!', '\\(', '\\)', '\\{', '\\}', '\\[', '\\]', '\\^',
     '\\~', '\\*', '\\?', '\\:', '\\"', '\\;', '\\ ', '\\AND', '\\OR', '\\NOT');
    $string = str_replace($match, $replace, $string);
 
    return $string;
}