Share » Forums » Extensions » eZ Find » Solr JSon query from ez module view

Solr JSon query from ez module view

Solr JSon query from ez module view

Wednesday 09 June 2010 2:30:45 am - 2 replies

Author Message

Carlos Revillo

Wednesday 09 June 2010 3:11:55 am

Manipulate the array seems the best choice to me. Could be as simple as

echo json_encode( $search )

Paul Borgermans

Wednesday 09 June 2010 8:57:02 am

When using the eZSolrBase->rawSolrRequest function you can issue a third parameter which specifies the response format ... which can be json instead of the default "php" (which is a PHP array)

 eZSolrBase->rawSolrRequest($request, $params, 'json')

That saves the json_encode step

The same is true when you use the rawSearch method (where the response format is the second argument)

hth

Paul

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu