Source for file LC_Page_Admin_Plugin_Install.php
Documentation is available at LC_Page_Admin_Plugin_Install.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.
require_once CLASS_EX_REALDIR . 'page_extends/admin/LC_Page_Admin_Ex.php';
* FIXME インストール直後のレンダリング時点では、上部ナビに反映されない
* TODO Transaction Token を使用する
* @version $Id: LC_Page_Admin_Plugin_Install.php 20970 2011-06-10 10:27:24Z Seasoft $
if (DEBUG_LOAD_PLUGIN !== true) SC_Utils_Ex::sfDispException('プラグインは有効化されていない'); // XXX 開発途上対応
$this->tpl_mainpage = 'plugin/install.tpl';
$this->tpl_mainno = 'plugin';
$this->tpl_subno = 'install';
$this->tpl_subtitle = 'プラグインのインストール';
$this->objFormParam = new SC_FormParam_Ex();
$this->objFormParam->setParam($_REQUEST);
$this->arrForm = $this->objFormParam->getHashArray();
$this->arrErr = $this->objFormParam->checkError();
if (count($this->arrErr) == 0) {
$this->tpl_result = '完了しました。';
SC_Utils_Ex::sfDispException();
// アンインストール SQL を実行 (クリーンアップ)
SC_Helper_DB_Ex::sfExecSqlByFile(PLUGIN_REALDIR . "$path/sql/uninstall.sql");
SC_Helper_DB_Ex::sfExecSqlByFile(PLUGIN_REALDIR . "$path/sql/install.sql");
$pluginsXml = SC_Utils_Ex::sfGetPluginsXml();
$addPluginXml = $pluginsXml->addChild('plugin');
$addPluginXml->addChild('path', $path);
$arrPluginInfo = SC_Utils_Ex::sfGetPluginInfoArray($path);
$addPluginXml->addChild('name', $arrPluginInfo['name']);
SC_Utils_Ex::sfPutPluginsXml($pluginsXml);
$this->objFormParam->addParam('プラグインのパス', 'path', STEXT_LEN, '', array('EXIST_CHECK', 'SPTAB_CHECK', 'MAX_LENGTH_CHECK'));
Documentation generated on Fri, 24 Feb 2012 14:01:31 +0900 by Seasoft
|