diff options
author | Thomas Steur <tsteur@users.noreply.github.com> | 2018-05-28 13:17:22 +0300 |
---|---|---|
committer | Matthieu Aubry <mattab@users.noreply.github.com> | 2018-05-28 13:17:22 +0300 |
commit | 51e725ede4378df7eeab296335ec5dab6a026b94 (patch) | |
tree | b7b33133d41f4585ef9be6e61ca8047aeeaacc35 /misc/others | |
parent | 0e70009736f2a874d78aa3388d8cce2f65cfdb41 (diff) |
Remove internal API example (#12996)
Diffstat (limited to 'misc/others')
-rw-r--r-- | misc/others/api_internal_call.php | 33 |
1 files changed, 0 insertions, 33 deletions
diff --git a/misc/others/api_internal_call.php b/misc/others/api_internal_call.php deleted file mode 100644 index 1790f3b8d4..0000000000 --- a/misc/others/api_internal_call.php +++ /dev/null @@ -1,33 +0,0 @@ -<?php -use Piwik\API\Request; -use Piwik\FrontController; - -define('PIWIK_INCLUDE_PATH', realpath('../..')); -define('PIWIK_USER_PATH', realpath('../..')); -define('PIWIK_ENABLE_DISPATCH', false); -define('PIWIK_ENABLE_ERROR_HANDLER', false); -define('PIWIK_ENABLE_SESSION_START', false); - -require_once PIWIK_INCLUDE_PATH . "/index.php"; -require_once PIWIK_INCLUDE_PATH . "/core/API/Request.php"; - -$environment = new \Piwik\Application\Environment(null); -$environment->init(); - -FrontController::getInstance()->init(); - -// This inits the API Request with the specified parameters -$request = new Request(' - module=API - &method=Resolution.getResolution - &idSite=7 - &date=yesterday - &period=week - &format=XML - &filter_limit=3 - &token_auth=anonymous -'); -// Calls the API and fetch XML data back -$result = $request->process(); -echo $result; - |