Changeset 822550 for goolytics-simple-google-analytics
- Timestamp:
- 12/15/2013 05:01:09 PM (12 years ago)
- Location:
- goolytics-simple-google-analytics/trunk
- Files:
-
- 68 added
- 3 edited
-
goolytics.php (modified) (6 diffs)
-
inc/google-api-php-client (added)
-
inc/google-api-php-client/src (added)
-
inc/google-api-php-client/src/Google_Client.php (added)
-
inc/google-api-php-client/src/auth (added)
-
inc/google-api-php-client/src/auth/Google_AssertionCredentials.php (added)
-
inc/google-api-php-client/src/auth/Google_Auth.php (added)
-
inc/google-api-php-client/src/auth/Google_AuthNone.php (added)
-
inc/google-api-php-client/src/auth/Google_LoginTicket.php (added)
-
inc/google-api-php-client/src/auth/Google_OAuth2.php (added)
-
inc/google-api-php-client/src/auth/Google_P12Signer.php (added)
-
inc/google-api-php-client/src/auth/Google_PemVerifier.php (added)
-
inc/google-api-php-client/src/auth/Google_Signer.php (added)
-
inc/google-api-php-client/src/auth/Google_Verifier.php (added)
-
inc/google-api-php-client/src/cache (added)
-
inc/google-api-php-client/src/cache/Google_ApcCache.php (added)
-
inc/google-api-php-client/src/cache/Google_Cache.php (added)
-
inc/google-api-php-client/src/cache/Google_FileCache.php (added)
-
inc/google-api-php-client/src/cache/Google_MemcacheCache.php (added)
-
inc/google-api-php-client/src/config.php (added)
-
inc/google-api-php-client/src/contrib (added)
-
inc/google-api-php-client/src/contrib/Google_AdexchangebuyerService.php (added)
-
inc/google-api-php-client/src/contrib/Google_AdsenseService.php (added)
-
inc/google-api-php-client/src/contrib/Google_AdsensehostService.php (added)
-
inc/google-api-php-client/src/contrib/Google_AnalyticsService.php (added)
-
inc/google-api-php-client/src/contrib/Google_BigqueryService.php (added)
-
inc/google-api-php-client/src/contrib/Google_BloggerService.php (added)
-
inc/google-api-php-client/src/contrib/Google_BooksService.php (added)
-
inc/google-api-php-client/src/contrib/Google_CalendarService.php (added)
-
inc/google-api-php-client/src/contrib/Google_ComputeService.php (added)
-
inc/google-api-php-client/src/contrib/Google_CustomsearchService.php (added)
-
inc/google-api-php-client/src/contrib/Google_DriveService.php (added)
-
inc/google-api-php-client/src/contrib/Google_FreebaseService.php (added)
-
inc/google-api-php-client/src/contrib/Google_FusiontablesService.php (added)
-
inc/google-api-php-client/src/contrib/Google_GanService.php (added)
-
inc/google-api-php-client/src/contrib/Google_LatitudeService.php (added)
-
inc/google-api-php-client/src/contrib/Google_LicensingService.php (added)
-
inc/google-api-php-client/src/contrib/Google_ModeratorService.php (added)
-
inc/google-api-php-client/src/contrib/Google_Oauth2Service.php (added)
-
inc/google-api-php-client/src/contrib/Google_OrkutService.php (added)
-
inc/google-api-php-client/src/contrib/Google_PagespeedonlineService.php (added)
-
inc/google-api-php-client/src/contrib/Google_PlusMomentsService.php (added)
-
inc/google-api-php-client/src/contrib/Google_PlusService.php (added)
-
inc/google-api-php-client/src/contrib/Google_PredictionService.php (added)
-
inc/google-api-php-client/src/contrib/Google_ShoppingService.php (added)
-
inc/google-api-php-client/src/contrib/Google_SiteVerificationService.php (added)
-
inc/google-api-php-client/src/contrib/Google_StorageService.php (added)
-
inc/google-api-php-client/src/contrib/Google_TaskqueueService.php (added)
-
inc/google-api-php-client/src/contrib/Google_TasksService.php (added)
-
inc/google-api-php-client/src/contrib/Google_TranslateService.php (added)
-
inc/google-api-php-client/src/contrib/Google_UrlshortenerService.php (added)
-
inc/google-api-php-client/src/contrib/Google_WebfontsService.php (added)
-
inc/google-api-php-client/src/contrib/Google_YoutubeService.php (added)
-
inc/google-api-php-client/src/external (added)
-
inc/google-api-php-client/src/external/URITemplateParser.php (added)
-
inc/google-api-php-client/src/io (added)
-
inc/google-api-php-client/src/io/Google_CacheParser.php (added)
-
inc/google-api-php-client/src/io/Google_CurlIO.php (added)
-
inc/google-api-php-client/src/io/Google_HttpRequest.php (added)
-
inc/google-api-php-client/src/io/Google_IO.php (added)
-
inc/google-api-php-client/src/io/Google_REST.php (added)
-
inc/google-api-php-client/src/io/cacerts.pem (added)
-
inc/google-api-php-client/src/service (added)
-
inc/google-api-php-client/src/service/Google_BatchRequest.php (added)
-
inc/google-api-php-client/src/service/Google_MediaFileUpload.php (added)
-
inc/google-api-php-client/src/service/Google_Model.php (added)
-
inc/google-api-php-client/src/service/Google_Service.php (added)
-
inc/google-api-php-client/src/service/Google_ServiceResource.php (added)
-
inc/google-api-php-client/src/service/Google_Utils.php (added)
-
inc/options.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
goolytics-simple-google-analytics/trunk/goolytics.php
r664341 r822550 2 2 /* 3 3 Plugin Name: Goolytics - Simple Google Analytics 4 Version: 1.0 4 Version: 1.0.1 5 5 Plugin URI: http://www.schloebe.de/wordpress/goolytics-plugin/ 6 6 Description: A simple Google Analytics solution that works without slowing down your WordPress installation. … … 36 36 * Define the plugin version 37 37 */ 38 define("GOOLYTICSVERSION", "1.0 ");38 define("GOOLYTICSVERSION", "1.0.1"); 39 39 40 40 /** … … 69 69 * initializing required stuff for the plugin 70 70 * 71 * PHP 4 Compatible Goolytics72 *73 * @since 1.074 * @author scripts@schloebe.de75 */76 function Goolytics() {77 $this->__construct();78 }79 80 81 /**82 * The Goolytics class constructor83 * initializing required stuff for the plugin84 *85 71 * PHP 5 Constructor 86 72 * … … 101 87 add_filter('plugin_action_links', array(&$this, 'plugin_action_links'), 10, 2); 102 88 103 add_action(' admin_init', array(&$this, 'load_textdomain'));89 add_action('plugins_loaded', array(&$this, 'load_textdomain')); 104 90 add_action('admin_init', array(&$this, 'admin_init')); 105 91 add_action('admin_menu', array(&$this, 'admin_menu_goolytics')); … … 107 93 if (!is_admin()) 108 94 add_action('wp_head', array(&$this, 'print_code')); 95 } 96 97 98 /** 99 * The Goolytics class constructor 100 * initializing required stuff for the plugin 101 * 102 * PHP 4 Compatible Goolytics 103 * 104 * @since 1.0 105 * @author scripts@schloebe.de 106 */ 107 function Goolytics() { 108 $this->__construct(); 109 109 } 110 110 … … 192 192 function load_textdomain() { 193 193 if($this->textdomain_loaded) return; 194 load_plugin_textdomain('goolytics', false, dirname(plugin_basename(__FILE__)) . '/languages ');194 load_plugin_textdomain('goolytics', false, dirname(plugin_basename(__FILE__)) . '/languages/'); 195 195 $this->textdomain_loaded = true; 196 196 } -
goolytics-simple-google-analytics/trunk/inc/options.php
r664341 r822550 1 <?php 2 require_once( trailingslashit(dirname(__FILE__)) . 'google-api-php-client/src/Google_Client.php'); 3 require_once( trailingslashit(dirname(__FILE__)) . 'google-api-php-client/src/contrib/Google_AnalyticsService.php'); 4 5 $client = new Google_Client(); 6 $client->setApplicationName("Goolytics - Simple Google Analytics"); 7 8 $service = new Google_AnalyticsService($client); 9 10 if (isset($_GET['logout'])) { 11 unset($_SESSION['token']); 12 } 13 14 if (isset($_GET['code'])) { 15 $client->authenticate(); 16 $_SESSION['token'] = $client->getAccessToken(); 17 $redirect = 'http://' . $_SERVER['HTTP_HOST'] . $_SERVER['PHP_SELF']; 18 header('Location: ' . filter_var($redirect, FILTER_SANITIZE_URL)); 19 } 20 21 if (isset($_SESSION['token'])) { 22 $client->setAccessToken($_SESSION['token']); 23 } 24 25 if ($client->getAccessToken()) { 26 $props = $service->management_webproperties->listManagementWebproperties("~all"); 27 print "<h1>Web Properties</h1><pre>" . print_r($props, true) . "</pre>"; 28 29 $accounts = $service->management_accounts->listManagementAccounts(); 30 print "<h1>Accounts</h1><pre>" . print_r($accounts, true) . "</pre>"; 31 32 $_SESSION['token'] = $client->getAccessToken(); 33 } else { 34 $authUrl = $client->createAuthUrl(); 35 print "<a class='login' href='$authUrl'>Connect Me!</a>"; 36 } 37 ?> 38 1 39 <div class="wrap"> 2 40 <h2>Goolytics - Simple Google Analytics</h2> -
goolytics-simple-google-analytics/trunk/readme.txt
r664341 r822550 4 4 Tags: google, analytics, web tracking, tracking, goolytics 5 5 Requires at least: 3.0 6 Tested up to: 3. 66 Tested up to: 3.9 7 7 Stable tag: trunk 8 8 License: GPLv2 or later … … 44 44 == Changelog == 45 45 46 = 1.0.1 = 47 * 'Redefining already defined constructor' bug that occured on several configurations 48 * WP 3.8 compatibility 49 46 50 = 1.0 = 47 51 * Initial release
Note: See TracChangeset
for help on using the changeset viewer.