本文整理汇总了PHP中Alert::make方法的典型用法代码示例。如果您正苦于以下问题:PHP Alert::make方法的具体用法?PHP Alert::make怎么用?PHP Alert::make使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Alert
的用法示例。
在下文中一共展示了Alert::make方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: allowOnlyRefer
public static function allowOnlyRefer($inputData)
{
$refer = Http::get('refer');
$inputData = str_replace('/', '\\/', $inputData);
if (!preg_match('/' . $inputData . '/i', $refer)) {
Alert::make('Page not found');
}
}
示例2: makeWithPath
public static function makeWithPath($viewName, $inputData, $themePath)
{
$filepath = $themePath . $viewName . '.php';
if (!file_exists($filepath)) {
Alert::make('View ' . $viewName . ' not exists.');
}
// $data=file_get_contents($themePath.$viewName);
$data = self::parseData($filepath);
extract($inputData);
include $data;
}
示例3: index
public function index()
{
System::systemStatus();
// if($match=Uri::match('^(\w+)$'))
// {
// echo $match[1];
// }
$themePath = System::getThemePath();
$indexPath = $themePath . 'index.php';
if (file_exists($indexPath)) {
Theme::checkDomain();
Theme::checkThemePrefix();
Theme::loadShortCode();
include $indexPath;
} else {
Alert::make('Theme not found');
}
}
示例4: index
public function index()
{
$controlName = 'admincp/controlDashboard';
if (Cookie::has('userid')) {
$valid = UserGroups::getPermission(Users::getCookieGroupId(), 'can_view_admincp');
if ($valid != 'yes') {
Alert::make('You not have permission to view this page');
}
$controlName = 'admincp/controlDashboard';
$default_adminpage_method = trim(System::getSetting('default_adminpage_method', 'none'));
if ($default_adminpage_method == 'url') {
$default_adminpage = trim(System::getSetting('default_adminpage_url', 'admincp/'));
if ($default_adminpage != 'admincp/' && System::getUri() == 'admincp/') {
$beginUri = 'admincp';
if ($default_adminpage[0] != '/') {
$beginUri .= '/';
}
System::setUri($beginUri . $default_adminpage);
}
}
if ($match = Uri::match('^admincp\\/(\\w+)')) {
$controlName = 'admincp/control' . ucfirst($match[1]);
}
} else {
$controlName = 'admincp/controlLogin';
if ($match = Uri::match('^admincp\\/forgotpass')) {
$controlName = 'admincp/controlForgotpass';
}
}
$codeHead = Plugins::load('admincp_header');
$codeHead = is_array($codeHead) ? '' : $codeHead;
$codeFooter = Plugins::load('admincp_footer');
$codeFooter = is_array($codeFooter) ? '' : $codeFooter;
// print_r($codeHead);die();
System::defineGlobalVar('admincp_header', $codeHead);
System::defineGlobalVar('admincp_footer', $codeFooter);
Controller::load($controlName);
}
示例5: array
<?php
if ((int) GlobalCMS::$setting['enable_rss'] == 0) {
Alert::make('Page not found');
}
$pageName = 'rss';
$pageData = array();
$headData = GlobalCMS::$setting;
Theme::model('rss');
$pageData['listPost'] = listRss();
$pageData['setting'] = $headData;
Theme::view($pageName, $pageData);
示例6: controller
public function controller()
{
$post = array();
if ($matchCtr = Uri::match('\\/setting\\/(\\w+)\\/controller\\/(\\w+)')) {
$controllerName = $matchCtr[2];
$themeName = $matchCtr[1];
$path = THEMES_PATH . $themeName . '/cp/controller/control' . ucfirst($controllerName) . '.php';
if (!file_exists($path)) {
Alert::make('Controller <b>' . $controllerName . '</b> of theme ' . $themeName . ' not found.');
}
define("THEME_CP_PATH", THEMES_PATH . $themeName . 'cp/');
$post['file'] = $path;
$post['themename'] = $themeName;
View::make('admincp/head', array('title' => 'Setting theme ' . $themeName . ' - ' . ADMINCP_TITLE));
self::makeContents('themeControl', $post);
View::make('admincp/footer');
}
}
示例7: onlyWord
public static function onlyWord()
{
global $cmsUri;
// echo $cmsUri;
// die();
if (preg_match('/[\\<\\>\\$]/i', $cmsUri)) {
Alert::make('Page not found');
}
}