📄 createhtml.inc.php
字号:
<?php
defined('IN_PHPCMS') or exit('Access Denied');
@set_time_limit(600);
$channelid = intval($channelid);
$channelid or showmessage($LANG['invalid_parameters'], $referer);
$referer=isset($referer) ? $referer : "?mod=$mod&file=$file&channelid=$channelid";
if(isset($action) && strpos($action, ','))
{
$actions=explode(',', $action);
$action=$actions[0];
unset($actions[0]);
$actions=implode(',', $actions);
$referer='?mod='.$mod.'&file='.$file.'&action='.$actions.'&channelid='.$channelid;
}
switch($action)
{
case 'index':
createhtml("index");
showmessage($LANG['update_channel_homepage_success'], $referer);
break;
case 'list'://鏍忕洰
if(isset($_SESSION['temp_cat_name'.$mod]))
{
include PHPCMS_ROOT.'/data/temp/'.$_SESSION['temp_cat_name'.$mod];
$catids = array_shift($cats_array);
if(!$catids)
{
unlink(PHPCMS_ROOT.'/data/temp/'.$_SESSION['temp_cat_name'.$mod]);
unset($_SESSION['temp_cat_name'.$mod]);
showmessage($LANG['update_success'],'?mod='.$mod.'&file=createhtml&channelid='.$channelid);
}
array_save($cats_array,"\$cats_array",PHPCMS_ROOT.'/data/temp/'.$_SESSION['temp_cat_name'.$mod]);
$referer = '?mod='.$mod.'&file='.$file.'&action='.$action.'&channelid='.$channelid;
}
if(empty($catids))
{
$catids = array();
foreach($CATEGORY as $r)
{
$catids[]=$r['catid'];
}
}
if(is_array($catids))
{
$_SESSION['temp_cat_name'.$mod] = 'T'.$PHP_TIME.'.php';
array_save($catids,"\$cats_array",PHPCMS_ROOT.'/data/temp/'.$_SESSION['temp_cat_name'.$mod]);
showmessage($LANG['updating'].$LANG['category'],'?mod='.$mod.'&file='.$file.'&action='.$action.'&channelid='.$channelid);
}
elseif(is_numeric($catids))
{
$catid = $catids;
createhtml('list');
showmessage($LANG['category'].' ['.$CATEGORY[$catids]['catname'].'] '.$LANG['update_success'], $referer);
}
break;
case 'per_list'://鍒嗘
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -