admin.php

来自「phpcms2007很好的cms内容管理系统,操作方便」· PHP 代码 · 共 16 行

PHP
16
字号
<?php
define('YP_ROOT_DIR', str_replace("\\", '/', dirname(__FILE__)));
require YP_ROOT_DIR.'/include/common.inc.php';
require PHPCMS_ROOT.'/languages/'.$CONFIG['adminlanguage'].'/yp_admin.lang.php';
if(!$_userid) showmessage($LANG['please_login'],$PHPCMS['siteurl'].'member/login.php?forward='.$PHP_URL);
require YP_ROOT_DIR.'/web/admin/include/common.inc.php';
if(isset($action) && $action == 'logout')
{
	mkcookie('auth', '');
	showmessage($LANG['logout_success']);
}
if(!isset($file)) $file = 'index';
preg_match("/^[0-9A-Za-z_]+$/",$file) or showmessage('Invalid Request.');
$filepath = YP_ROOT_DIR.'/web/admin/'.$file.'.inc.php';
if(!@include $filepath) showmessage($LANG['illegal_operation']);
?>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?