Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormatt <matt@59fd770c-687e-43c8-a1e3-f5a4ff64c105>2008-06-26 03:57:04 +0400
committermatt <matt@59fd770c-687e-43c8-a1e3-f5a4ff64c105>2008-06-26 03:57:04 +0400
commit623a8d24a81bc9964bc1e7c0dbed4388a9255713 (patch)
treeb79022f051e04bf50d426cb00c3c5ea392575931 /plugins/API
parent4654c59b7f84eeedf284ec4dbcb7609c26ae4323 (diff)
- converting line breaks to UNIX
Diffstat (limited to 'plugins/API')
-rw-r--r--plugins/API/API.php52
-rw-r--r--plugins/API/Controller.php134
2 files changed, 93 insertions, 93 deletions
diff --git a/plugins/API/API.php b/plugins/API/API.php
index 473f49042e..af64f74cb4 100644
--- a/plugins/API/API.php
+++ b/plugins/API/API.php
@@ -1,27 +1,27 @@
-<?php
-/**
- * Piwik - Open source web analytics
- *
- * @link http://piwik.org
- * @license http://www.gnu.org/licenses/gpl-3.0.html Gpl v3 or later
- * @version $Id: ExamplePlugin.php 169 2008-01-14 05:41:15Z matt $
- *
- * @package Piwik_PluginsAdmin
- */
-
-class Piwik_API extends Piwik_Plugin
-{
- public function getInformation()
- {
- return array(
- // name must be the className prefix!
- 'name' => 'API',
- 'description' => '',
- 'author' => 'Piwik',
- 'homepage' => 'http://piwik.org/',
- 'version' => '0.1',
- );
- }
-}
-
+<?php
+/**
+ * Piwik - Open source web analytics
+ *
+ * @link http://piwik.org
+ * @license http://www.gnu.org/licenses/gpl-3.0.html Gpl v3 or later
+ * @version $Id: ExamplePlugin.php 169 2008-01-14 05:41:15Z matt $
+ *
+ * @package Piwik_PluginsAdmin
+ */
+
+class Piwik_API extends Piwik_Plugin
+{
+ public function getInformation()
+ {
+ return array(
+ // name must be the className prefix!
+ 'name' => 'API',
+ 'description' => '',
+ 'author' => 'Piwik',
+ 'homepage' => 'http://piwik.org/',
+ 'version' => '0.1',
+ );
+ }
+}
+
Piwik_AddAdminMenu('API', array('module' => 'API', 'action' => 'listAllAPI')); \ No newline at end of file
diff --git a/plugins/API/Controller.php b/plugins/API/Controller.php
index a32c6c26b2..e411626b2d 100644
--- a/plugins/API/Controller.php
+++ b/plugins/API/Controller.php
@@ -1,58 +1,58 @@
-<?php
-/**
- * Piwik - Open source web analytics
- *
- * @link http://piwik.org
- * @license http://www.gnu.org/licenses/gpl-3.0.html Gpl v3 or later
- * @version $Id$
- *
- * @package Piwik_API
- */
-
-require_once "API/Request.php";
-
-
-/**
- *
- * @package Piwik_API
- */
-class Piwik_API_Controller extends Piwik_Controller
-{
- function index()
- {
- $request = new Piwik_API_Request();
- echo $request->process();
- }
-
- protected function init()
- {
- $plugins = Piwik_PluginsManager::getInstance()->getLoadedPluginsName();
-
- $loaded = 0;
- foreach( $plugins as $plugin )
- {
- $plugin = Piwik::unprefixClass($plugin);
-
- try {
- Piwik_API_Proxy::getInstance()->registerClass($plugin);
- $loaded++;
- }
- catch(Exception $e){
- }
- }
- return $loaded;
- }
-
- function listAllMethods()
- {
- $this->init();
- echo Piwik_API_Proxy::getInstance()->getAllInterfaceString( $outputExampleUrls = true, $prefixUrls = Piwik_Common::getRequestVar('prefixUrl', '') );
- }
-
-
- function listAllAPI()
- {
- $token_auth = Zend_Registry::get('auth')->getTokenAuth();
+<?php
+/**
+ * Piwik - Open source web analytics
+ *
+ * @link http://piwik.org
+ * @license http://www.gnu.org/licenses/gpl-3.0.html Gpl v3 or later
+ * @version $Id$
+ *
+ * @package Piwik_API
+ */
+
+require_once "API/Request.php";
+
+
+/**
+ *
+ * @package Piwik_API
+ */
+class Piwik_API_Controller extends Piwik_Controller
+{
+ function index()
+ {
+ $request = new Piwik_API_Request();
+ echo $request->process();
+ }
+
+ protected function init()
+ {
+ $plugins = Piwik_PluginsManager::getInstance()->getLoadedPluginsName();
+
+ $loaded = 0;
+ foreach( $plugins as $plugin )
+ {
+ $plugin = Piwik::unprefixClass($plugin);
+
+ try {
+ Piwik_API_Proxy::getInstance()->registerClass($plugin);
+ $loaded++;
+ }
+ catch(Exception $e){
+ }
+ }
+ return $loaded;
+ }
+
+ function listAllMethods()
+ {
+ $this->init();
+ echo Piwik_API_Proxy::getInstance()->getAllInterfaceString( $outputExampleUrls = true, $prefixUrls = Piwik_Common::getRequestVar('prefixUrl', '') );
+ }
+
+
+ function listAllAPI()
+ {
+ $token_auth = Zend_Registry::get('auth')->getTokenAuth();
echo "<style>body{ font-family:georgia,arial; font-size:0.95em;}
#token_auth {
background-color:#E8FFE9;
@@ -66,15 +66,15 @@ class Piwik_API_Controller extends Piwik_Controller
.example, .example A {
color:#9E9E9E;
}
- </style>";
- echo sprintf(Piwik_Translate('API_QuickDocumentation'),$token_auth);
- echo "<span id='token_auth'>token_auth = <b>$token_auth</b></span>";
-
- $loaded = $this->init();
- echo "<p><i> ".sprintf(Piwik_Translate('API_LoadedAPIs'),$loaded)."</i></p>\n";
-
- echo Piwik_API_Proxy::getInstance()->getAllInterfaceString();
- }
-
-}
-
+ </style>";
+ echo sprintf(Piwik_Translate('API_QuickDocumentation'),$token_auth);
+ echo "<span id='token_auth'>token_auth = <b>$token_auth</b></span>";
+
+ $loaded = $this->init();
+ echo "<p><i> ".sprintf(Piwik_Translate('API_LoadedAPIs'),$loaded)."</i></p>\n";
+
+ echo Piwik_API_Proxy::getInstance()->getAllInterfaceString();
+ }
+
+}
+