本文整理汇总了PHP中Cloud::change_updatedate方法的典型用法代码示例。如果您正苦于以下问题:PHP Cloud::change_updatedate方法的具体用法?PHP Cloud::change_updatedate怎么用?PHP Cloud::change_updatedate使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Cloud
的用法示例。
在下文中一共展示了Cloud::change_updatedate方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: elseif
$dou->dou_msg($_LANG['plugin_edit_succes'], 'plugin.php');
} elseif ($rec == 'disable') {
// 验证并获取合法的ID
$unique_id = $check->is_extend_id($_REQUEST['unique_id']) ? $_REQUEST['unique_id'] : '';
$name = $dou->get_one("SELECT name FROM " . $dou->table('plugin') . " WHERE unique_id = '{$unique_id}'");
$dou->create_admin_log($_LANG['plugin_disable_succes'] . ': ' . $name);
$dou->delete($dou->table('plugin'), "unique_id = '{$unique_id}'");
$dou->dou_header('plugin.php');
} elseif ($rec == 'del') {
if ($check->is_extend_id($unique_id = $_REQUEST['unique_id'])) {
// 载入扩展功能
include_once ROOT_PATH . ADMIN_PATH . '/include/cloud.class.php';
$dou_cloud = new Cloud('cache');
if (isset($_POST['confirm']) ? $_POST['confirm'] : '') {
$plugin_array = $dou->get_subdirs($plugin_dir);
if (in_array($unique_id, $plugin_array)) {
// 判断删除操作的插件是否真实存在
$dou->del_dir($plugin_dir . $unique_id);
$dou_cloud->change_updatedate('plugin', $unique_id, true);
// 删除更新时间记录
$dou->create_admin_log($_LANG['plugin_del'] . ': ' . $unique_id);
$dou->dou_header('plugin.php');
}
} else {
$_LANG['del_check'] = preg_replace('/d%/Ums', $unique_id, $_LANG['del_check']);
$dou->dou_msg($_LANG['del_check'], 'plugin.php', '', '30', "plugin.php?rec=del&unique_id={$unique_id}");
}
} else {
$dou->dou_header('plugin.php');
}
}
示例2: elseif
* 模板启用
* +----------------------------------------------------------
*/
if ($rec == 'enable') {
if ($check->is_extend_id($unique_id = $_REQUEST['unique_id'])) {
$theme_array = $dou->get_subdirs(ROOT_PATH . 'theme/');
if (in_array($unique_id, $theme_array)) {
// 判断删除操作的模板是否真实存在
// 替换系统设置中模板值
$dou->query("UPDATE " . $dou->table('config') . " SET value = '{$unique_id}' WHERE name = 'site_theme'");
$dou->dou_clear_cache(ROOT_PATH . "cache");
// 更新缓存
}
}
$dou->dou_header('theme.php');
} elseif ($rec == 'del') {
// 载入扩展功能
include_once ROOT_PATH . ADMIN_PATH . '/include/cloud.class.php';
$dou_cloud = new Cloud('cache');
if ($check->is_extend_id($unique_id = $_REQUEST['unique_id'])) {
$theme_array = $dou->get_subdirs(ROOT_PATH . 'theme/');
if (in_array($unique_id, $theme_array)) {
// 判断删除操作的模板是否真实存在
$dou->del_dir(ROOT_PATH . 'theme/' . $unique_id);
$dou_cloud->change_updatedate('theme', $unique_id, true);
// 删除更新时间记录
$dou->create_admin_log($_LANG['theme_del'] . ': ' . $unique_id);
}
}
$dou->dou_header('theme.php');
}
示例3: Cloud
*/
if ($rec == 'del') {
// 载入扩展功能
include_once ROOT_PATH . ADMIN_PATH . '/include/cloud.class.php';
$dou_cloud = new Cloud('cache');
// CSRF防御令牌验证
$firewall->check_token($_REQUEST['token'], 'module_uninstall');
if ($check->is_extend_id($extend_id = $_REQUEST['extend_id'])) {
$module_zip = $cache_dir . $extend_id . '.zip';
// 模块压缩包
$module_dir = $cache_dir . $extend_id;
// 模块目录
if ($dou_cloud->file_unzip($module_zip, $module_dir)) {
$dou_cloud->modify_theme_dir($module_dir);
// 将解压得到的扩展目录中的模板文件夹名改成当前启用的模板文件夹名
$dou_cloud->clear_module($extend_id);
$dou_cloud->change_updatedate('module', $extend_id, true);
// 删除更新时间记录
$dou->del_dir($module_dir);
@unlink($module_zip);
$dou->query("DELETE FROM " . $dou->table('nav') . " WHERE module = '{$extend_id}'");
$dou->query("DELETE FROM " . $dou->table('nav') . " WHERE module = '{$extend_id}" . "_category'");
$dou->create_admin_log($_LANG['module_uninstall_success'] . ': ' . $extend_id);
$dou->dou_header('module.php?rec=uninstall');
} else {
$dou->dou_msg($_LANG['module_unzip_wrong'], 'module.php?rec=uninstall');
}
} else {
$dou->dou_msg($_LANG['module_uninstall_wrong'], 'module.php?rec=uninstall');
}
}
示例4: get_cfg_list
$dou->query("UPDATE " . $dou->table('config') . " SET value = '{$unique_id}' WHERE name = 'mobile_theme'");
$dou->dou_clear_cache(ROOT_PATH . 'cache/m');
// 更新缓存
}
}
$dou->dou_header('mobile.php?rec=theme');
} elseif ($act == 'del') {
// 载入扩展功能
include_once ROOT_PATH . ADMIN_PATH . '/include/cloud.class.php';
$dou_cloud = new Cloud('cache');
if ($check->is_extend_id($unique_id = $_REQUEST['unique_id'])) {
$theme_array = $dou->get_subdirs(ROOT_PATH . M_PATH . '/theme/');
if (in_array($unique_id, $theme_array)) {
// 判断删除操作的模板是否真实存在
$dou->del_dir(ROOT_PATH . M_PATH . '/theme/' . $unique_id);
$dou_cloud->change_updatedate('mobile', $unique_id, true);
// 删除更新时间记录
$dou->create_admin_log($_LANG['mobile_theme_del'] . ': ' . $unique_id);
}
}
$dou->dou_header('mobile.php?rec=theme');
}
}
/**
* +----------------------------------------------------------
* 获取系统设置列表
* +----------------------------------------------------------
*/
function get_cfg_list($tab = 'main')
{
$sql = "SELECT * FROM " . $GLOBALS['dou']->table('config') . " WHERE tab = 'mobile' ORDER BY sort ASC";