本文整理汇总了PHP中buildframes函数的典型用法代码示例。如果您正苦于以下问题:PHP buildframes函数的具体用法?PHP buildframes怎么用?PHP buildframes使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了buildframes函数的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: pdo_fetchall
<?php
/**
* [WeEngine System] Copyright (c) 2014 WE7.CC
* WeEngine is NOT a free software, it under the license terms, visited http://www.we7.cc/ for more details.
*/
$GLOBALS['top_nav'] = pdo_fetchall('SELECT name, title, append_title FROM ' . tablename('core_menu') . ' WHERE pid = 0 AND is_display = 1 ORDER BY displayorder DESC');
buildframes();
$_W['page']['title'] = '模拟测试';
$development = 1;
$accounts = uni_owned();
foreach ($accounts as &$account) {
if ($account['default_acid'] > 0) {
$account['default_account'] = pdo_fetch('SELECT acid,token,name FROM ' . tablename('account_wechats') . ' WHERE acid = :acid', array(':acid' => $account['default_acid']));
} else {
$account['default_account'] = pdo_fetch('SELECT acid,token,name FROM ' . tablename('account_wechats') . ' WHERE uniacid = :uniacid ORDER BY level DESC LIMIT 1', array(':uniacid' => $account['uniacid']));
$account['default_acid'] = $account['default_account']['acid'];
}
}
unset($account);
template('common/header');
?>
<style type="text/css">
.chatPanel .left{float:left;}
.chatPanel .right{float:right;}
.chatPanel .media a{display:block;}
.chatPanel .media{border:1px solid #cdcdcd;box-shadow:0 3px 6px #999999;-webkit-border-radius:12px;-moz-border-radius:12px;border-radius:12px;width:285px;background-color:#FFFFFF;background:-webkit-gradient(linear,left top,left bottom,from(#FFFFFF),to(#FFFFFF));background-image:-moz-linear-gradient(top,#FFFFFF 0%,#FFFFFF 100%);margin:0px auto;}
.chatPanel .media .mediaPanel{padding:0px;margin:0px;}
.chatPanel .media .mediaImg{margin:25px 15px 15px;width:255px;position:relative;}
.chatPanel .media .mediaImg .mediaImgPanel{position:relative;padding:0px;margin:0px;max-height:164px;overflow:hidden;}
.chatPanel .media .mediaImg img{/* width:100%;height:164px;position:absolute;left:0px;*/width:255px;}
示例2: define
<?php
/**
* [WeEngine System] Copyright (c) 2014 WE7.CC
* WeEngine is NOT a free software, it under the license terms, visited http://www.we7.cc/ for more details.
*/
define('FRAME', 'mc');
$frames = buildframes(array('mc'));
$frames = $frames['mc'];
if ($controller == 'wechat') {
if (in_array($action, array('manage', 'card'))) {
define('ACTIVE_FRAME_URL', url('wechat/account'));
}
}
示例3: defined
<?php
/**
* [Weizan System] Copyright (c) 2014 wdlcms.com
* Weizan is NOT a free software, it under the license terms, visited http://www.wdlcms.com/ for more details.
*/
defined('IN_IA') or exit('Access Denied');
$dos = array('platform', 'site', 'mc', 'setting', 'ext', 'solution');
$do = in_array($do, $dos) ? $do : 'platform';
$title = array('platform' => '公众平台', 'site' => '微站功能', 'mc' => '会员及会员营销', 'setting' => '功能选项', 'ext' => '扩展功能', 'solution' => '行业功能');
$_W['page']['title'] = $title[$do];
define('FRAME', $do);
$frames = buildframes(array(FRAME), $_GPC['m']);
$frames = $frames[FRAME];
if (!empty($_W['setting']['permurls']['sections']) && !in_array($do, $_W['setting']['permurls']['sections'])) {
header('Location: ' . url('home/welcome/' . $_W['setting']['permurls']['sections'][0]));
exit;
}
if ($do != 'solution') {
if (!empty($_W['setting']['permurls']['urls'])) {
foreach ($_W['setting']['permurls']['urls'] as $url) {
if (strexists($url, 'c=home&a=welcome&do=ext')) {
parse_str($url, $urls);
$showmodules[] = $urls['m'];
}
}
}
$modules = uni_modules();
$settings = uni_setting($_W['uniacid'], array('shortcuts'));
$shorts = $settings['shortcuts'];
if (!is_array($shorts)) {
示例4: message
message('错误访问.');
}
$module = module_fetch($m);
if (empty($module) || empty($module['isrulefields'])) {
message('访问无权限.');
}
if (!in_array($m, $sysmods)) {
if ($module['issolution']) {
$solution = $module;
define('FRAME', 'solution');
} else {
define('FRAME', 'ext');
$types = module_types();
define('ACTIVE_FRAME_URL', url('home/welcome/ext', array('m' => $m)));
}
$frames = buildframes(array(FRAME), $m);
$frames = $frames[FRAME];
}
$_W['page']['title'] = $module['title'];
load()->model('extension');
if (ext_module_checkupdate($module)) {
message('系统检测到该模块有更新,请点击“<a href="' . url('extension/module/upgrade', array('m' => $m)) . '">更新模块</a>”后继续使用!', '', 'error');
}
if (in_array($m, array('custom'))) {
$site = WeUtility::createModuleSite($m);
$site_urls = $site->getTabUrls();
}
if ($do == 'display') {
$pindex = max(1, intval($_GPC['page']));
$psize = 20;
$cids = $parentcates = $list = array();
示例5: define
<?php
/**
* [Weizan System] Copyright (c) 2014 012WZ.COM
* Weizan is NOT a free software, it under the license terms, visited http://www.012wz.com/ for more details.
*/
if ($do == 'oauth' || $action == 'credit' || $action == 'passport' || $action == 'uc') {
define('FRAME', 'setting');
} else {
define('FRAME', 'mc');
}
if ($action == 'stat') {
define('ACTIVE_FRAME_URL', url('mc/trade'));
}
$frames = buildframes(array(FRAME));
$frames = $frames[FRAME];
示例6: define
$solutions[] = $module;
}
} else {
$solutions[] = $module;
}
}
}
}
} else {
define('FRAME', 'ext');
define('CRUMBS_NAV', 1);
$ptr_title = $entry['title'];
$module_types = module_types();
define('ACTIVE_FRAME_URL', url('home/welcome/ext', array('m' => $entry['module'])));
}
$frames = buildframes(array(FRAME), $entry['module']);
$frames = $frames[FRAME];
}
if (!empty($entry['module'])) {
load()->model('extension');
if (ext_module_checkupdate($entry['module'])) {
message('系统检测到该模块有更新,请点击“<a href="' . url('extension/module/upgrade', array('m' => $entry['module'])) . '">更新模块</a>”后继续使用!', '', 'error');
}
}
$_GPC['__entry'] = $entry['title'];
$_GPC['__state'] = $entry['state'];
if (!empty($_W['modules'][$entry['module']]['handles']) && (count($_W['modules'][$entry['module']]['handles']) > 1 || !in_array('text', $_W['modules'][$entry['module']]['handles']))) {
$handlestips = true;
}
$site = WeUtility::createModuleSite($entry['module']);
define('IN_MODULE', $entry['module']);
示例7: pdo_query
if (empty($_GPC['permurls'])) {
pdo_query("DELETE FROM " . tablename('users_permission') . " WHERE uid = '{$uid}'");
} else {
foreach ($_GPC['permurls'] as $url) {
if (($pos = array_search($url, $hasurls)) !== FALSE) {
unset($hasurls[$pos]);
continue;
}
parse_str($url, $tokens);
pdo_insert('users_permission', array('uid' => $uid, 'uniacid' => $uniacid, 'url' => $url));
}
pdo_query("DELETE FROM " . tablename('users_permission') . " WHERE uid = '{$uid}' AND id IN ('" . implode("','", array_keys($hasurls)) . "')");
}
message('操作菜单权限成功!', url('user/permission/menu', array('uid' => $uid, 'uniacid' => $uniacid)), 'success');
}
$menus = buildframes(array('platform', 'site', 'mc', 'setting', 'ext'));
template('user/menu');
}
if ($do == 'auth') {
$uniacid = intval($_GPC['uniacid']);
$uid = intval($uid);
$isexists = pdo_fetch("SELECT * FROM " . tablename('uni_account_users') . " WHERE uid = :uid AND uniacid = :uniacid", array(':uid' => $uid, ':uniacid' => $uniacid));
if (empty($isexists)) {
pdo_insert('uni_account_users', array('uniacid' => $uniacid, 'uid' => $uid));
}
exit('success');
}
if ($do == 'revo') {
$uniacid = intval($_GPC['uniacid']);
$uid = intval($uid);
$isexists = pdo_fetch("SELECT * FROM " . tablename('uni_account_users') . " WHERE uid = :uid AND uniacid = :uniacid", array(':uid' => $uid, ':uniacid' => $uniacid));
示例8: module_entries
$entries = module_entries($m, array($type['name']));
if (empty($entries)) {
message('访问错误, 当前模块不提供此功能.');
}
if ($module['issolution']) {
$solution = $module;
define('FRAME', 'solution');
} else {
define('FRAME', 'ext');
$types = module_types();
define('ACTIVE_FRAME_URL', url('home/welcome/ext', array('m' => $module['name'])));
}
} else {
define('FRAME', 'site');
}
$frames = buildframes(array(FRAME), $module['name']);
$frames = $frames[FRAME];
if ($_W['ispost']) {
$ret = intval($_GPC['ret']) == '1' ? 1 : 0;
$set = @json_decode(base64_decode($_GPC['dat']), true);
if (is_array($set)) {
if (!empty($set['id'])) {
$sql = $sql = 'SELECT * FROM ' . tablename('site_nav') . ' WHERE id = :id';
$pars[':id'] = $set['id'];
} else {
$sql = 'SELECT * FROM ' . tablename('site_nav') . ' WHERE `position`=:position AND `uniacid`=:uniacid AND `module`=:module AND `url`=:url';
$pars[':uniacid'] = $_W['uniacid'];
$pars[':module'] = $set['module'];
$pars[':position'] = $type['position'];
$pars[':url'] = $set['url'];
}