Source for file SC_Helper_Plugin.php
Documentation is available at SC_Helper_Plugin.php
* This file is part of EC-CUBE
* Copyright(c) 2000-2011 LOCKON CO.,LTD. All Rights Reserved.
* http://www.lockon.co.jp/
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* @version $Id: SC_Helper_Plugin.php 20870 2011-04-20 07:13:08Z nanasess $
$objQuery = new SC_Query_Ex();
$where = "enable = 1 AND del_flg = 0";
$arrCols = $objQuery->listTableFields($table);
$objQuery->setOrder('rank');
$arrRet = $objQuery->select($col, $table, $where);
// 現在のページで使用するプラグインが存在するかどうかを検証する
foreach ($arrRet as $plugins){
// プラグインを稼働させるクラス名のリストを取得する
// プラグインのディレクトリ内の設定ファイルを参照する
$plugin_name = $plugins['plugin_name'];
$plugin_class_name = $plugins['class_name'];
$plugin_path = DATA_REALDIR . "plugin/{$plugin_name}/{$plugin_class_name}.php";
require_once $plugin_path;
$code_str = "\$is_enable = {$plugin_class_name}::isEnable(\$class_name);";
$arrPluginList[] = $plugin_class_name;
GC_Utils_Ex::gfDebugLog($class_name . ' で、プラグイン ' . $plugin_name . ' をロードしました');
GC_Utils_Ex::gfDebugLog($class_name . ' で、プラグイン ' . $plugin_name . ' は無効になっています');
GC_Utils_Ex::gfDebugLog('プラグイン ' . $plugin_name . ' の ' . $class_name . ' が見つかりませんでした');
GC_Utils_Ex::gfDebugLog('プラグイン ' . $plugin_name . " が読み込めませんでした。\n"
. 'Failed opening required ' . $plugin_path);
//プラグインの名前を判別してページ内で有効なプラグインがあれば実行する
$arrPluginList = SC_Helper_Plugin_Ex::load($lcpage);
if(count($arrPluginList) > 0){
foreach ($arrPluginList as $key => $value){
$instance->preProcess($lcpage);
//プラグインの名前を判別してページ内で有効なプラグインがあれば実行する
$arrPluginList = SC_Helper_Plugin_Ex::load($lcpage);
if(count($arrPluginList) > 0){
foreach ($arrPluginList as $key => $value){
$instance->process($lcpage);
$objQuery = new SC_Query_Ex();
$where = 'enable = 1 AND del_flg = 0';
$arrCols = $objQuery->listTableFields($table);
$objQuery->setOrder('rank DESC');
$arrRet = $objQuery->select($col,$table,$where);
$objQuery = new SC_Query_Ex();
$arrCols = $objQuery->listTableFields($table);
$objQuery->setOrder('rank DESC');
$arrRet = $objQuery->select($col,$table,$where);
$plugin_dir = DATA_REALDIR. "/plugin/";
while(($file = readdir($dh) !== false)){
if(is_dir($plugin_dir. "/". $file)){
Documentation generated on Fri, 24 Feb 2012 14:02:46 +0900 by Seasoft
|