SolrDisMaxQuery::setTrigramPhraseFields

(No version information available, might only be in Git)
Directly Sets Trigram Phrase Fields (pf3 parameter)
public SolrDisMaxQuery SolrDisMaxQuery::setTrigramPhraseFields ( string $fields )

Directly Sets Trigram Phrase Fields (pf3 parameter)

Parameters:
fields

Trigram Phrase Fields

Returns:

SolrDisMaxQuery

Examples:
SolrDisMaxQuery::setTrigramPhraseFields() example
<?php

$dismaxQuery = new SolrDisMaxQuery('lucene');
$dismaxQuery->setTrigramPhraseFields('cat~5.1^2 feature^4.5');
echo $dismaxQuery.PHP_EOL;

?>

The above example will output:

q=lucene&defType=edismax&pf3=cat~5.1^2 feature^4.5
See also:

SolrDisMaxQuery::addTrigramPhraseField() -

SolrDisMaxQuery::removeTrigramPhraseField() -

SolrDisMaxQuery::setTrigramPhraseSlop() -

doc_php
2016-02-24 16:11:48
Comments
Leave a Comment

Please login to continue.