Skip to content

Commit

Permalink
JSON reply to JSON request
Browse files Browse the repository at this point in the history
  • Loading branch information
kanoi committed Dec 20, 2011
1 parent da79851 commit aacf1e5
Show file tree
Hide file tree
Showing 2 changed files with 324 additions and 119 deletions.
3 changes: 3 additions & 0 deletions api-example.php
Expand Up @@ -59,6 +59,9 @@ function request($cmd)

print "$cmd returned '$line'\n";

if (substr($line,0,1) == '{')
return json_decode($line, true);

$data = array();

$objs = explode('|', $line);
Expand Down

0 comments on commit aacf1e5

Please sign in to comment.