diff options
author | Andrew Dolgov <[email protected]> | 2011-11-28 09:35:13 +0400 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2011-11-28 09:35:13 +0400 |
commit | 582f41e2c16a5235c8315071a4c4d8352ec209d6 (patch) | |
tree | d6f099e0bc4321748afb92d5b5151f1c26cfef68 /api | |
parent | db16ae5008f76e020a20f7138f3647511e94d542 (diff) |
implement getApiLevel
Diffstat (limited to 'api')
-rw-r--r-- | api/index.php | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/api/index.php b/api/index.php index 333eb0dc9..e00ca097d 100644 --- a/api/index.php +++ b/api/index.php @@ -7,6 +7,8 @@ require_once "../db-prefs.php"; require_once "../functions.php"; + define('API_LEVEL', 1); + define('API_STATUS_OK', 0); define('API_STATUS_ERR', 1); @@ -78,6 +80,11 @@ print api_wrap_reply(API_STATUS_OK, $seq, $rv); break; + case "getApiLevel": + $rv = array("level" => API_LEVEL); + print api_wrap_reply(API_STATUS_OK, $seq, $rv); + break; + case "login": $login = db_escape_string($_REQUEST["user"]); $password = $_REQUEST["password"]; |