0
votes

I am using SolrPhpClient with Drupal and i want to use drupal as higher-layer user-interface to be able to query and retrieve search results from "apache solr"

I tried to use this example here (http://code.google.com/p/solr-php-client/wiki/ExampleUsage) for testing if drupal works with SolrPhpClient, but i am getting two errors which are presented below

1) Deprecated function: Function split() is deprecated in ApacheSolr_Response->_construct() (line 117 of /var/www/drupal/sites/all/modules/apachesolr/SolrPhpClient/Apache/Solr/Response.php).

2) Warning: htmlspecialchars() expects parameter 1 to be string, array given in eval() (line 80 of /var/www/drupal/modules/php/php.module(75) : eval()'d code). Does anyone in reddit use SolrPhpClient before ? I have never used PHP so had a difficult time understanding it ?

Any kind of help will be appreciated

Many Thanks

1
Why don't you use the Apache Solr module? It does what you described and has a LOT of functionality. Or there's a reason not to use it? - Miguel LomelĂ­

1 Answers

1
votes

split function is deprecated in PHP 5.3.0. So use explode function instead of split. http://patelmilap.wordpress.com/2011/09/07/list-of-deprecated-functions-php/

And please tell me what are you passing in htmlspecialchars() function ?
It is used to Convert special characters to HTML entities.
http://php.net/manual/en/function.htmlspecialchars.php