Skip to content
kerrishotts edited this page Nov 13, 2012 · 1 revision

(part of PKUTIL)

Return Type: void

Parameters: theURL ( string ), completion ( function )

Attempts to load the JSON resource specified by theURL. Completion will be called with two parameters: the first indicating success or failure, and the second containing the successfully parsed object (if the load was successful and the object could be parsed). If an error occurs, it is logged to the console.

For example:

PKUTIL.loadJSON ( "http://api.twitter.com/1.1/search.json", 
                  doSomethingWithTheData );

Version

0.1 Introduced

0.2 Docs Valid

Clone this wiki locally