Warning: file_get_contents(https://raw.githubusercontent.com/Den1xxx/Filemanager/master/languages/ru.json): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 88

Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 215

Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 216

Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 217

Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 218

Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 219

Warning: Cannot modify header information - headers already sent by (output started at /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php:88) in /home/afelisqd/cppseducation.sc.tz/admin/images/photos/17587263121019776732_admin-dbb.php on line 220
--TEST-- Solr Bug #72740 - addPhraseField return wrong query --SKIPIF-- --FILE-- SOLR_SERVER_HOSTNAME, 'login' => SOLR_SERVER_USERNAME, 'password' => SOLR_SERVER_PASSWORD, 'port' => SOLR_SERVER_PORT, 'path' => SOLR_SERVER_PATH ); $client = new SolrClient( $options ); $dismaxQuery = new SolrDisMaxQuery( '*:*' ); $dismaxQuery->addPhraseField( "phraseField1", 10, 5 ); $dismaxQuery->addPhraseField( "phraseField2", 5, 1 ); $dismaxQuery->addSortField('score', SolrQuery::ORDER_DESC); $dismaxQuery->addSortField('manufacturedate_dt', SolrQuery::ORDER_DESC); // Scenario 1: DisMax Query Parser - Adds Phrase Fields with both boost and slop. // Expect: // - pf parameter should list each phrase field with ~ and ^ prefix for slop and boost value respectively. $queryResponse = $client->query( $dismaxQuery ); print_r($queryResponse->getResponse()->responseHeader->params); // Scenario 2: Same as Scenario 1, now including explicit query fields too. // Expect: // - pf parameter should list each phrase field with ~ and ^ prefix for slop and boost value respectively. // - qf parameter should list each query field with a trailing ^ (no boost here). $dismaxQuery->addQueryField('score'); $dismaxQuery->addQueryField('manufacturedate_dt'); $queryResponse = $client->query( $dismaxQuery ); print_r($queryResponse->getResponse()->responseHeader->params); // Scenario 3: Same as Scenario 2, now including explicit boost value for the query fields. // Expect: // - pf parameter should list each phrase field with ~ and ^ prefix for slop and boost value respectively. // - qf parameter should list each query field with a ^ prefix for boost value. $dismaxQuery->removeQueryField('score'); $dismaxQuery->removeQueryField('manufacturedate_dt'); $dismaxQuery->addQueryField('score', 3); $dismaxQuery->addQueryField('manufacturedate_dt', 7); $queryResponse = $client->query( $dismaxQuery ); print_r($queryResponse->getResponse()->responseHeader->params); ?> --EXPECTF-- SolrObject Object ( [q] => *:* [defType] => edismax [indent] => on [pf] => phraseField1~5^10 phraseField2~1^5 [sort] => score desc,manufacturedate_dt desc [version] => 2.2 [wt] => xml ) SolrObject Object ( [q] => *:* [defType] => edismax [indent] => on [qf] => score^ manufacturedate_dt^ [pf] => phraseField1~5^10 phraseField2~1^5 [sort] => score desc,manufacturedate_dt desc [version] => 2.2 [wt] => xml ) SolrObject Object ( [q] => *:* [defType] => edismax [indent] => on [qf] => score^3 manufacturedate_dt^7 [pf] => phraseField1~5^10 phraseField2~1^5 [sort] => score desc,manufacturedate_dt desc [version] => 2.2 [wt] => xml )