diff options
Diffstat (limited to 'public_html/api')
-rw-r--r-- | public_html/api/index.php | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/public_html/api/index.php b/public_html/api/index.php new file mode 100644 index 0000000..5146e3d --- /dev/null +++ b/public_html/api/index.php @@ -0,0 +1,16 @@ +<?php + require_once( dirname(__FILE__) . "/../../lib/functions.php"); + + if (!valid_login()) { + need_login(); + } + + if (!empty($_GET['object']) && !empty($_GET['action'])) { + if (function_exists($_GET['object'] . '_' . $_GET['action'])) { + call_user_func_array($_GET['object'] . '_' . $_GET['action']); + } elseif (file_exists(dirname(__FILE__) . "/../../lib/actions/" . $_GET['object'] . '_' . $_GET['action'] . ".php")) { + require_once(dirname(__FILE__) . "/../../lib/actions/" . $_GET['object'] . '_' . $_GET['action'] . ".php"); + } + } + +?> |