Changeset 18370 for branches/comu-ver2/html/user_data/plugins
- Timestamp:
- 2009/11/07 01:38:52 (17 years ago)
- Location:
- branches/comu-ver2/html/user_data/plugins
- Files:
-
- 3 added
- 1 deleted
- 5 edited
- 4 moved
-
google_analytics/admin (added)
-
google_analytics/admin/index.php (moved) (moved from branches/comu-ver2/html/user_data/plugins/google_analytics/index.php) (2 diffs)
-
google_analytics/classes/pages/LC_Page_Admin_GoogleAnalytics.php (modified) (4 diffs)
-
google_analytics/classes/pages/LC_Page_FrontParts_Bloc_GoogleAnalytics.php (modified) (2 diffs)
-
google_analytics/ga.php (modified) (2 diffs)
-
google_analytics/plugin_info.php (added)
-
google_analytics/require.php (modified) (1 diff)
-
google_analytics/sql/install.sql (moved) (moved from branches/comu-ver2/html/user_data/plugins/google_analytics/sql/insert.sql)
-
google_analytics/sql/uninstall.sql (moved) (moved from branches/comu-ver2/html/user_data/plugins/google_analytics/sql/delete.sql)
-
google_analytics/tpl/admin (added)
-
google_analytics/tpl/admin/index.tpl (moved) (moved from branches/comu-ver2/html/user_data/plugins/google_analytics/tpl/index.tpl) (1 diff)
-
plugin_menu.tpl (deleted)
-
plugins.xml (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
branches/comu-ver2/html/user_data/plugins/google_analytics/admin/index.php
r18345 r18370 22 22 */ 23 23 // {{{ requires 24 require_once("../../../admin/require.php"); 25 require_once(USER_PATH . 'plugins/google_analytics/classes/pages/LC_Page_Admin_GoogleAnalytics.php'); 24 require_once '../../../../admin/require.php'; 25 $arrPluginInfo = SC_Utils_Ex::sfLoadPluginInfo('../plugin_info.php'); 26 require_once $arrPluginInfo['fullpath'] . 'classes/pages/LC_Page_Admin_GoogleAnalytics.php'; 26 27 27 28 // }}} … … 29 30 30 31 $objPage = new LC_Page_Admin_GoogleAnalytics(); 32 $objPage->arrPluginInfo = $arrPluginInfo; 31 33 register_shutdown_function(array($objPage, 'destroy')); 32 34 $objPage->init(); -
branches/comu-ver2/html/user_data/plugins/google_analytics/classes/pages/LC_Page_Admin_GoogleAnalytics.php
r18345 r18370 34 34 class LC_Page_Admin_GoogleAnalytics extends LC_Page { 35 35 36 /** プラグイン情報配列 (呼び出し元でセットする) */ 37 var $arrPluginInfo; 38 36 39 // }}} 37 40 // {{{ functions … … 44 47 function init() { 45 48 parent::init(); 46 $this->tpl_mainpage = PLUGIN_PATH . 'google_analytics/tpl/index.tpl'; 47 $this->tpl_subtitle = "Google Analytics Plugin"; 49 $this->tpl_mainpage = $this->arrPluginInfo['fullpath'] . 'tpl/admin/index.tpl'; 50 $this->tpl_mainno = 'plugin'; 51 $this->tpl_subno = $this->arrPluginInfo['path']; 52 $this->tpl_subtitle = "プラグイン「{$this->arrPluginInfo['name']}」の設定"; 48 53 49 54 if (empty($_POST["mode"])) { … … 102 107 $objView = new SC_AdminView(); 103 108 $objView->assignobj($this); 104 $objView->display( $this->tpl_mainpage);109 $objView->display(MAIN_FRAME); 105 110 } 106 111 … … 118 123 . htmlspecialchars($ua, ENT_QUOTES) . "');\n?>\n"; 119 124 120 $configFile = PLUGIN_PATH . "google_analytics/classes/pages/ga_config.php";125 $configFile = $this->arrPluginInfo['fullpath'] . "classes/pages/ga_config.php"; 121 126 $handle = fopen($configFile, "w"); 122 127 if (!$handle) { -
branches/comu-ver2/html/user_data/plugins/google_analytics/classes/pages/LC_Page_FrontParts_Bloc_GoogleAnalytics.php
r18345 r18370 34 34 class LC_Page_FrontParts_Bloc_GoogleAnalytics extends LC_Page { 35 35 36 /** プラグイン情報配列 (呼び出し元でセットする) */ 37 var $arrPluginInfo; 38 36 39 // }}} 37 40 // {{{ functions … … 44 47 function init() { 45 48 parent::init(); 46 $this->tpl_mainpage = USER_PATH . 'plugins/google_analytics/tpl/ga.tpl'; 47 $this->tpl_subtitle = "Google Analytics Plugin"; 49 $this->tpl_mainpage = $this->arrPluginInfo['fullpath'] . 'tpl/ga.tpl'; 48 50 } 49 51 -
branches/comu-ver2/html/user_data/plugins/google_analytics/ga.php
r18345 r18370 1 1 <?php 2 /* 3 * This file is part of EC-CUBE 4 * 5 * Copyright(c) 2000-2009 LOCKON CO.,LTD. All Rights Reserved. 6 * 7 * http://www.lockon.co.jp/ 8 * 9 * This program is free software; you can redistribute it and/or 10 * modify it under the terms of the GNU General Public License 11 * as published by the Free Software Foundation; either version 2 12 * of the License, or (at your option) any later version. 13 * 14 * This program is distributed in the hope that it will be useful, 15 * but WITHOUT ANY WARRANTY; without even the implied warranty of 16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 * GNU General Public License for more details. 18 * 19 * You should have received a copy of the GNU General Public License 20 * along with this program; if not, write to the Free Software 21 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 22 */ 23 2 24 // {{{ requires 3 require_once(PLUGIN_PATH . "google_analytics/classes/pages/LC_Page_FrontParts_Bloc_GoogleAnalytics.php"); 25 $arrPluginInfo = SC_Utils_Ex::sfLoadPluginInfo(dirname(__FILE__) . '/plugin_info.php'); 26 require_once $arrPluginInfo['fullpath'] . 'classes/pages/LC_Page_FrontParts_Bloc_GoogleAnalytics.php'; 4 27 5 28 // }}} … … 7 30 8 31 $objPage = new LC_Page_FrontParts_Bloc_GoogleAnalytics(); 9 register_shutdown_function(array($objPage, "destroy")); 32 $objPage->arrPluginInfo = $arrPluginInfo; 33 register_shutdown_function(array($objPage, 'destroy')); 10 34 $objPage->init(); 11 35 $objPage->process(); -
branches/comu-ver2/html/user_data/plugins/google_analytics/require.php
r18345 r18370 3 3 * EC-CUBE 本体で, このプラグインの関数を使用したい場合は, ここで require する 4 4 */ 5 require_once( PLUGIN_PATH . "google_analytics/classes/pages/ga_config.php");5 require_once(dirname(__FILE__) . '/classes/pages/ga_config.php'); 6 6 ?> -
branches/comu-ver2/html/user_data/plugins/google_analytics/tpl/admin/index.tpl
r18345 r18370 1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 2 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="ja" lang="ja"> 3 4 <head> 5 <meta http-equiv="content-type" content="application/xhtml+xml; charset=<!--{$smarty.const.CHAR_CODE}-->" /> 6 <meta http-equiv="content-script-type" content="text/javascript" /> 7 <meta http-equiv="content-style-type" content="text/css" /> 8 <link rel="stylesheet" href="<!--{$TPL_DIR}-->css/admin_contents.css" type="text/css" media="all" /> 9 <script type="text/javascript" src="<!--{$TPL_DIR}-->js/css.js"></script> 10 <script type="text/javascript" src="<!--{$TPL_DIR}-->js/navi.js"></script> 11 <script type="text/javascript" src="<!--{$TPL_DIR}-->js/win_op.js"></script> 12 <script type="text/javascript" src="<!--{$TPL_DIR}-->js/site.js"></script> 13 <script type="text/javascript" src="<!--{$TPL_DIR}-->js/jquery.js"></script> 14 <script type="text/javascript" src="<!--{$TPL_DIR}-->js/admin.js"></script> 15 <title><!--{$tpl_subtitle}--></title> 16 <script type="text/javascript"> 17 18 </script> 19 <style type="text/css"> 20 @charset "UTF-8"; 21 </style> 22 </head> 23 24 <body onload="<!--{$tpl_onload}-->" class="authority_0" style="min_width: 400px"> 25 <noscript> 26 <p>JavaScript を有効にしてご利用下さい.</p> 27 </noscript> 28 29 <div id="container"> 30 <a name="top"></a> 31 <!--▼CONTENTS--> 32 <h1>Google Analytics Plugin</h1> 33 <div id="contents" class="clear-block"> 34 <form method="post" action="index.php"> 1 <form method="post" action="index.php"> 35 2 <div id="system" class="contents-main"> 36 <table class="list">37 <tr>38 <th>ウェブ プロパティ ID</th>39 <td>UA-<input type="text" name="ga_ua" value="<!--{$smarty.const.GA_UA}-->" /></td>40 </tr>41 </table>42 <div class="btn addnew">43 <input type="hidden" name="mode" value="register" />44 <button type="submit"><span>この内容で登録する</span></button>45 </div>3 <table class="list"> 4 <tr> 5 <th>ウェブ プロパティ ID</th> 6 <td>UA-<input type="text" name="ga_ua" value="<!--{$smarty.const.GA_UA}-->" /></td> 7 </tr> 8 </table> 9 <div class="btn addnew"> 10 <input type="hidden" name="mode" value="register" /> 11 <button type="submit"><span>この内容で登録する</span></button> 12 </div> 46 13 </div> 47 </form> 48 </div> 49 <!--▲CONTENTS--> 50 </div> 51 </body> 52 </html> 14 </form> -
branches/comu-ver2/html/user_data/plugins/plugins.xml
r18345 r18370 1 1 <?xml version="1.0" encoding="utf-8"?> 2 2 <plugins> 3 <plugin>4 <name>Google Analytics</name>5 <path>google_analytics</path>6 </plugin>7 3 </plugins>
Note: See TracChangeset
for help on using the changeset viewer.
