You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-commits@lucene.apache.org by Apache Wiki <wi...@apache.org> on 2006/11/08 16:31:47 UTC

[Solr Wiki] Update of "SolJSON" by YonikSeeley

Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Solr Wiki" for change notification.

The following page has been changed by YonikSeeley:
http://wiki.apache.org/solr/SolJSON

The comment on the change is:
document json.wrf

------------------------------------------------------------------------------
   * wt=json - enable JSON output
   * json.nl=map - the default... !NamedList is represented as a JSON object.  Although this is the simplest mapping, a !NamedList can have optional keys, repeated keys, and preserves order.  Using a JSON object (essentially a map or hash) for a !NamedList results in the loss of some information.
   * json.nl=arrarr - represent a !NamedList as an array of two element arrays {{{[[name1,val1], [name2, val2], [name3,val3]]}}}
+  * json.wrf=function - adds a wrapper-function around the JSON response, useful in AJAX with dynamic script tags for specifying a !JavaScript callback function.
+    * http://www.xml.com/pub/a/2005/12/21/json-dynamic-script-tag.html
+    * http://www.theurer.cc/blog/2005/12/15/web-services-json-dump-your-proxy/
  
  == Using Solr's JSON output for AJAX ==
  Solr's JSON output makes parsing the response in !JavaScript simple.  Since JSON is a subset of !JavaScript, one