mirror of
https://github.com/typecho/typecho.git
synced 2025-03-20 01:49:40 +01:00
将“激活”修改为“启用”
This commit is contained in:
parent
e9ac9af2bb
commit
60f1d87069
@ -357,20 +357,17 @@ button.primary:active, button.primary.active {
|
||||
*/
|
||||
.message {
|
||||
padding: 5px 10px;
|
||||
font-size: 14px;
|
||||
color: #333;
|
||||
margin-bottom: 10px;
|
||||
|
||||
-moz-border-radius: 4px;
|
||||
-webkit-border-radius: 4px;
|
||||
-khtml-border-radius: 4px;
|
||||
-moz-border-radius: 3px;
|
||||
-webkit-border-radius: 3px;
|
||||
-khtml-border-radius: 3px;
|
||||
|
||||
/* hope IE support border radius, God save me! */
|
||||
border-radius: 4px;
|
||||
border-radius: 3px;
|
||||
}
|
||||
|
||||
.message a {
|
||||
color: #333;
|
||||
border-bottom: 1px dashed #aaa;
|
||||
line-height: 20px;
|
||||
}
|
||||
@ -383,7 +380,6 @@ button.primary:active, button.primary.active {
|
||||
.message blockquote {
|
||||
margin: 5px 10px;
|
||||
padding: 0 5px;
|
||||
font-size: 13px;
|
||||
}
|
||||
|
||||
.error {
|
||||
@ -421,14 +417,11 @@ button.primary:active, button.primary.active {
|
||||
|
||||
/** 增加顶部消息样式 by 70 */
|
||||
.popup {
|
||||
width: 928px;
|
||||
border-top: none;
|
||||
position: absolute;
|
||||
position: relative;
|
||||
z-index: 10;
|
||||
text-align: center;
|
||||
font-size: 13px;
|
||||
font-weight: bold;
|
||||
padding: 3px 10px;
|
||||
display: none;
|
||||
|
||||
-moz-border-radius-topleft: 0;
|
||||
@ -441,6 +434,12 @@ button.primary:active, button.primary.active {
|
||||
border-top-right-radius: 0;
|
||||
}
|
||||
|
||||
.popup ul {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* 安装样式
|
||||
*
|
||||
|
@ -10,7 +10,7 @@ include 'menu.php';
|
||||
<div class="col-12 typecho-list">
|
||||
<?php Typecho_Widget::widget('Widget_Plugins_List_Activated')->to($activatedPlugins); ?>
|
||||
<?php if ($activatedPlugins->have()): ?>
|
||||
<!--<h4 class="typecho-list-table-title"><?php _e('激活的插件'); ?></h4>-->
|
||||
<!--<h4 class="typecho-list-table-title"><?php _e('启用的插件'); ?></h4>-->
|
||||
<table class="typecho-list-table">
|
||||
<colgroup>
|
||||
<col width="25%"/>
|
||||
@ -49,7 +49,7 @@ include 'menu.php';
|
||||
<?php endif; ?>
|
||||
<a lang="<?php _e('你确认要禁用插件 %s 吗?', $activatedPlugins->name); ?>" href="<?php $options->index('/action/plugins-edit?deactivate=' . $activatedPlugins->name); ?>"><?php _e('禁用'); ?></a>
|
||||
<?php else: ?>
|
||||
<a href="<?php $options->index('/action/plugins-edit?activate=' . $activatedPlugins->name); ?>"><?php _e('激活'); ?></a>
|
||||
<a href="<?php $options->index('/action/plugins-edit?activate=' . $activatedPlugins->name); ?>"><?php _e('启用'); ?></a>
|
||||
<?php endif; ?>
|
||||
<?php else: ?>
|
||||
<span class="important"><?php _e('即插即用'); ?></span>
|
||||
@ -110,7 +110,7 @@ include 'menu.php';
|
||||
<?php endif; ?>
|
||||
<a href="<?php $options->index('/action/plugins-edit?deactivate=' . $deactivatedPlugins->name); ?>"><?php _e('禁用'); ?></a>
|
||||
<?php else: ?>
|
||||
<a href="<?php $options->index('/action/plugins-edit?activate=' . $deactivatedPlugins->name); ?>"><?php _e('激活'); ?></a>
|
||||
<a href="<?php $options->index('/action/plugins-edit?activate=' . $deactivatedPlugins->name); ?>"><?php _e('启用'); ?></a>
|
||||
<?php endif; ?>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
|
@ -43,7 +43,7 @@ include 'menu.php';
|
||||
<?php if($options->theme != $themes->name): ?>
|
||||
<p>
|
||||
<a class="edit" href="<?php $options->adminUrl('theme-editor.php?theme=' . $themes->name); ?>"><?php _e('编辑'); ?></a>
|
||||
<a class="activate" href="<?php $options->index('/action/themes-edit?change=' . $themes->name); ?>"><?php _e('激活'); ?></a>
|
||||
<a class="activate" href="<?php $options->index('/action/themes-edit?change=' . $themes->name); ?>"><?php _e('启用'); ?></a>
|
||||
</p>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
|
@ -34,7 +34,7 @@ class Helper
|
||||
/** 获取插件入口 */
|
||||
list($pluginFileName, $className) = Typecho_Plugin::portal($pluginName, __TYPECHO_ROOT_DIR__ . '/' . __TYPECHO_PLUGIN_DIR__);
|
||||
|
||||
/** 获取已激活插件 */
|
||||
/** 获取已启用插件 */
|
||||
$plugins = Typecho_Plugin::export();
|
||||
$activatedPlugins = $plugins['activated'];
|
||||
|
||||
|
@ -18,7 +18,7 @@
|
||||
class Typecho_Plugin
|
||||
{
|
||||
/**
|
||||
* 所有激活的插件
|
||||
* 所有启用的插件
|
||||
*
|
||||
* @access private
|
||||
* @var array
|
||||
@ -135,7 +135,7 @@ class Typecho_Plugin
|
||||
}
|
||||
|
||||
/**
|
||||
* 激活插件
|
||||
* 启用插件
|
||||
*
|
||||
* @access public
|
||||
* @param string $pluginName 插件名称
|
||||
|
@ -18,7 +18,7 @@
|
||||
interface Typecho_Plugin_Interface
|
||||
{
|
||||
/**
|
||||
* 激活插件方法,如果激活失败,直接抛出异常
|
||||
* 启用插件方法,如果启用失败,直接抛出异常
|
||||
*
|
||||
* @static
|
||||
* @access public
|
||||
|
@ -83,7 +83,7 @@ class Widget_Plugins_Config extends Widget_Abstract_Options
|
||||
/** 获取插件名称 */
|
||||
$pluginName = $this->request->config;
|
||||
|
||||
/** 获取已激活插件 */
|
||||
/** 获取已启用插件 */
|
||||
$plugins = Typecho_Plugin::export();
|
||||
$activatedPlugins = $plugins['activated'];
|
||||
|
||||
|
@ -67,7 +67,7 @@ class Widget_Plugins_Edit extends Widget_Abstract_Options implements Widget_Inte
|
||||
}
|
||||
|
||||
/**
|
||||
* 激活插件
|
||||
* 启用插件
|
||||
*
|
||||
* @access public
|
||||
* @return void
|
||||
@ -82,7 +82,7 @@ class Widget_Plugins_Edit extends Widget_Abstract_Options implements Widget_Inte
|
||||
list ($version, $build) = explode('/', Typecho_Common::VERSION);
|
||||
if (Typecho_Plugin::checkDependence($build, $info['dependence'])) {
|
||||
|
||||
/** 获取已激活插件 */
|
||||
/** 获取已启用插件 */
|
||||
$plugins = Typecho_Plugin::export();
|
||||
$activatedPlugins = $plugins['activated'];
|
||||
|
||||
@ -92,7 +92,7 @@ class Widget_Plugins_Edit extends Widget_Abstract_Options implements Widget_Inte
|
||||
/** 判断实例化是否成功 */
|
||||
if (isset($activatedPlugins[$pluginName]) || !class_exists($className)
|
||||
|| !method_exists($className, 'activate')) {
|
||||
throw new Typecho_Widget_Exception(_t('无法激活插件'), 500);
|
||||
throw new Typecho_Widget_Exception(_t('无法启用插件'), 500);
|
||||
}
|
||||
|
||||
try {
|
||||
@ -135,7 +135,7 @@ class Widget_Plugins_Edit extends Widget_Abstract_Options implements Widget_Inte
|
||||
if (isset($result) && is_string($result)) {
|
||||
$this->widget('Widget_Notice')->set($result, NULL, 'notice');
|
||||
} else {
|
||||
$this->widget('Widget_Notice')->set(_t('插件已经被激活'), NULL, 'success');
|
||||
$this->widget('Widget_Notice')->set(_t('插件已经被启用'), NULL, 'success');
|
||||
}
|
||||
$this->response->goBack();
|
||||
}
|
||||
@ -148,7 +148,7 @@ class Widget_Plugins_Edit extends Widget_Abstract_Options implements Widget_Inte
|
||||
*/
|
||||
public function deactivate($pluginName)
|
||||
{
|
||||
/** 获取已激活插件 */
|
||||
/** 获取已启用插件 */
|
||||
$plugins = Typecho_Plugin::export();
|
||||
$activatedPlugins = $plugins['activated'];
|
||||
$pluginFileExist = true;
|
||||
|
@ -19,7 +19,7 @@
|
||||
class Widget_Plugins_List extends Typecho_Widget
|
||||
{
|
||||
/**
|
||||
* 已激活插件
|
||||
* 已启用插件
|
||||
*
|
||||
* @access public
|
||||
* @var array
|
||||
@ -38,7 +38,7 @@ class Widget_Plugins_List extends Typecho_Widget
|
||||
$pluginDirs = glob(__TYPECHO_ROOT_DIR__ . '/' . __TYPECHO_PLUGIN_DIR__ . '/*');
|
||||
$this->parameter->setDefault(array('activated' => NULL));
|
||||
|
||||
/** 获取已激活插件 */
|
||||
/** 获取已启用插件 */
|
||||
$plugins = Typecho_Plugin::export();
|
||||
$this->activatedPlugins = $plugins['activated'];
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
*/
|
||||
|
||||
/**
|
||||
* 激活插件列表组件
|
||||
* 启用插件列表组件
|
||||
*
|
||||
* @author qining
|
||||
* @category typecho
|
||||
|
@ -338,7 +338,7 @@ class Widget_Users_Profile extends Widget_Users_Edit implements Widget_Interface
|
||||
/** 获取插件名称 */
|
||||
$pluginName = $this->request->plugin;
|
||||
|
||||
/** 获取已激活插件 */
|
||||
/** 获取已启用插件 */
|
||||
$plugins = Typecho_Plugin::export();
|
||||
$activatedPlugins = $plugins['activated'];
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user