本文整理汇总了PHP中pageAccess函数的典型用法代码示例。如果您正苦于以下问题:PHP pageAccess函数的具体用法?PHP pageAccess怎么用?PHP pageAccess使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了pageAccess函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: viewTagsAdmin
/**
* Admin interface
*/
public function viewTagsAdmin()
{
global $aidlink;
pageAccess('F');
add_breadcrumb(array('link' => INFUSIONS . 'forum/admin/forums.php' . $aidlink . '§ion=ft', 'title' => self::$locale['forum_tag_0100']));
echo "<div class='well'>" . self::$locale['forum_tag_0101'] . "</div>\n";
$tab['title'][] = self::$locale['forum_tag_0102'];
$tab['id'][] = "tag_list";
$tab['icon'][] = "";
$tab['title'][] = isset($_GET['tag_id']) && isnum($_GET['tag_id']) ? self::$locale['forum_tag_0104'] : self::$locale['forum_tag_0103'];
$tab['id'][] = "tag_form";
$tab['icon'][] = "";
$_GET['ref'] = isset($_GET['ref']) && in_array($_GET['ref'], $tab['id']) ? $_GET['ref'] : "tag_list";
echo opentab($tab, $_GET['ref'], "rank_admin", TRUE, "m-t-10", "ref");
switch ($_GET['ref']) {
case "tag_form":
echo $this->displayTagForm();
break;
case "tag_list":
echo $this->displayTagList();
}
echo closetab();
}
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:26,代码来源:tags.php
示例2: viewRanksAdmin
public function viewRanksAdmin()
{
global $aidlink;
pageAccess('FR');
add_breadcrumb(array('link' => INFUSIONS . 'forum/admin/forums.php' . $aidlink . '§ion=fr', 'title' => self::$locale['404']));
$forum_settings = $this->get_forum_settings();
echo "<div class='well'>" . self::$locale['forum_rank_0100'] . "</div>\n";
if ($forum_settings['forum_ranks']) {
$tab['title'][] = self::$locale['402'];
$tab['id'][] = "rank_list";
$tab['icon'][] = "";
$tab['title'][] = isset($_GET['rank_id']) && isnum($_GET['rank_id']) ? self::$locale['401'] : self::$locale['400'];
$tab['id'][] = "rank_form";
$tab['icon'][] = "";
$_GET['ref'] = isset($_GET['ref']) && in_array($_GET['ref'], $tab['id']) ? $_GET['ref'] : "rank_list";
echo opentab($tab, $_GET['ref'], "rank_admin", TRUE, "m-t-10", "ref");
switch ($_GET['ref']) {
case "rank_form":
// @todo: improvise rank from ui
echo $this->displayRanksForm();
break;
case "rank_list":
echo $this->displayRankList();
}
echo closetab();
} else {
opentable(self::$locale['403']);
?>
<div class="well text-center">
<?php
echo sprintf(self::$locale['450'], "<a href='" . FUSION_SELF . $aidlink . "§ion=fs'>" . self::$locale['451'] . "</a>");
?>
</div>
<?php
closetable();
}
}
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:37,代码来源:ranks.php
示例3: viewMoodAdmin
public function viewMoodAdmin()
{
global $aidlink;
pageAccess('FR');
add_breadcrumb(array('link' => INFUSIONS . 'forum/admin/forums.php' . $aidlink . '§ion=fmd', 'title' => self::$locale['forum_admin_004']));
echo "<div class='well'>" . self::$locale['forum_090'] . "</div>\n";
$tab['title'][] = self::$locale['forum_093'];
$tab['id'][] = "mood_list";
$tab['icon'][] = "";
$tab['title'][] = isset($_GET['mood_id']) && isnum($_GET['mood_id']) ? self::$locale['forum_092'] : self::$locale['forum_091'];
$tab['id'][] = "mood_form";
$tab['icon'][] = "";
$_GET['ref'] = isset($_GET['ref']) && in_array($_GET['ref'], $tab['id']) ? $_GET['ref'] : "mood_list";
echo opentab($tab, $_GET['ref'], "mood_admin", TRUE, "m-t-10", "ref");
switch ($_GET['ref']) {
case "mood_form":
$this->displayMoodForm();
break;
case "mood_list":
$this->displayMoodList();
break;
}
echo closetab();
}
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:24,代码来源:mood.php
示例4: pageAccess
<?php
require_once "inx/global.inc.php";
// only accesible to SuperAdmin and Administrator
pageAccess($_SESSION["auth"]["roles"], array('SuperAdmin', 'Administrator'));
$page = new HTML_Page2($page_defaults);
$sql = "SELECT use_id,use_fname,use_sname FROM user";
$q = $db->query($sql);
if (DB::isError($q)) {
die("db error: " . $q->getMessage());
}
while ($row = $q->fetchRow()) {
$users[$row["use_id"]] = $row["use_fname"] . ' ' . $row["use_sname"];
}
$formData1 = array('use_id' => array('type' => 'select', 'label' => 'User', 'value' => $use_id, 'options' => $users, 'attributes' => array('class' => 'addr'), 'required' => 2), 'use_password' => array('type' => 'text', 'label' => 'Password', 'value' => $use_password, 'attributes' => array('class' => 'addr'), 'required' => 2, 'tooltip' => 'Passwords must be at least 8 characters, and contain at least one number and one UPPER CASE letter'));
if (!$_GET["action"]) {
$form = new Form();
$form->addForm("", "get", $PHP_SELF);
$form->addHtml("<div id=\"standard_form\">\n");
$form->addField("hidden", "action", "", "reset");
/////////////////////////////////////////////////////////////////////////////////
$form->addHtml("<fieldset>\n");
$form->addHtml('<div class="block-header">Reset Password</div>');
$form->addData($formData1, $_GET);
$form->addHtml($form->addDiv($form->makeField("submit", "", "", "Save Changes", array('class' => 'submit'))));
$form->addHtml("</fieldset>\n");
$form->addHtml('<pre>');
for ($i = 1; $i <= 5; ++$i) {
$form->addHtml(random_string(16, 'safe') . "\n");
}
$form->addHtml('</pre>');
开发者ID:jankichaudhari,项目名称:yii-site,代码行数:31,代码来源:reset_pw.php
示例5: display_forum_admin
public function display_forum_admin()
{
global $aidlink;
opentable(self::$locale['forum_000c']);
$tab_title['title'][] = self::$locale['forum_admin_000'];
$tab_title['id'][] = 'fm';
$tab_title['icon'][] = '';
$tab_title['title'][] = self::$locale['forum_admin_001'];
$tab_title['id'][] = 'fr';
$tab_title['icon'][] = '';
$tab_title['title'][] = self::$locale['forum_admin_002'];
$tab_title['id'][] = 'ft';
$tab_title['icon'][] = '';
$tab_title['title'][] = self::$locale['forum_admin_004'];
$tab_title['id'][] = 'fmd';
$tab_title['icon'][] = '';
$tab_title['title'][] = self::$locale['forum_admin_003'];
$tab_title['id'][] = 'fs';
$tab_title['icon'][] = '';
echo opentab($tab_title, isset($_GET['section']) ? $_GET['section'] : 'fm', 'forum-admin-tabs', TRUE);
if (isset($_GET['section'])) {
switch ($_GET['section']) {
case 'fr':
$this->viewRank()->viewRanksAdmin();
break;
case 'ft':
$this->viewTags()->viewTagsAdmin();
break;
case 'fmd':
$this->viewMood()->viewMoodAdmin();
break;
case 'fs':
$this->viewSettings()->viewSettingsAdmin();
break;
default:
redirect(INFUSIONS . 'forum/admin/forums.php' . $aidlink);
}
} else {
pageAccess('F');
add_breadcrumb(array('link' => INFUSIONS . 'forum/admin/forums.php' . $aidlink, 'title' => self::$locale['forum_admin_000']));
$this->display_forum_index();
}
echo closetab();
closetable();
}
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:45,代码来源:view.php
示例6: tab_active
$tab_title['icon'][] = '';
$tab_active = tab_active($tab_title, isset($_GET['section']) ? $_GET['section'] : 'fm', true);
echo opentab($tab_title, $tab_active, 'fmm', true);
if (isset($_GET['section'])) {
switch ($_GET['section']) {
case 'fr':
pageAccess('FR');
add_breadcrumb(array('link' => INFUSIONS . 'forum/admin/forums.php' . $aidlink . '§ion=fr', 'title' => $locale['404']));
echo opentabbody($tab_title['title'][1], $tab_title['id'][1], $tab_active, true, 'section');
include INFUSIONS . 'forum/admin/forum_ranks.php';
echo closetabbody();
break;
case 'fs':
pageAccess('F');
echo opentabbody($tab_title['title'][2], $tab_title['id'][2], $tab_active, true, 'section');
include INFUSIONS . 'forum/admin/settings_forum.php';
echo closetabbody();
break;
default:
redirect(INFUSIONS . 'forum/admin/forums.php' . $aidlink);
}
} else {
pageAccess('F');
add_breadcrumb(array('link' => INFUSIONS . 'forum/admin/forums.php' . $aidlink, 'title' => $locale['forum_admin_000']));
echo opentabbody($tab_title['title'][0], $tab_title['id'][0], $tab_active, true, 'section');
$forum_admin->display_forum_admin();
echo closetabbody();
}
echo closetab();
closetable();
require_once THEMES . "templates/footer.php";
开发者ID:knapnet,项目名称:PHP-Fusion,代码行数:31,代码来源:forums.php
示例7: Copyright
| Copyright (C) PHP-Fusion Inc
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: user_log.php
| Author: gh0st2k
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "../maincore.php";
pageAccess('UL');
require_once THEMES . "templates/admin_header.php";
include LOCALE . LOCALESET . "admin/user_log.php";
add_breadcrumb(array('link' => ADMIN . 'administrators.php' . $aidlink, 'title' => $locale['100']));
if (!isset($_GET['rowstart']) || !isnum($_GET['rowstart'])) {
$_GET['rowstart'] = 0;
}
// Set default values
$dbOrder = "ORDER BY userlog_timestamp DESC";
$dbWhere = "";
$dbWhereCount = "";
$getString = $aidlink;
$orderby = "userlog_timestamp";
$expr = "DESC";
$user = "";
$userField = "";
开发者ID:knapnet,项目名称:PHP-Fusion,代码行数:31,代码来源:user_log.php
示例8: Copyright
| PHP-Fusion Content Management System
| Copyright (C) PHP-Fusion Inc
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: admin/blog_settings.php
| Author: Frederick MC Chan (Chan)
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
pageAccess("S8");
if (isset($_POST['savesettings'])) {
$error = 0;
$inputArray = array("article_pagination" => form_sanitizer($_POST['article_pagination'], 0, "article_pagination"), "article_allow_submission" => form_sanitizer($_POST['article_allow_submission'], 0, "article_allow_submission"), "article_extended_required" => isset($_POST['article_extended_required']) ? 1 : 0);
if (defender::safe()) {
foreach ($inputArray as $settings_name => $settings_value) {
$inputSettings = array("settings_name" => $settings_name, "settings_value" => $settings_value, "settings_inf" => "article");
dbquery_insert(DB_SETTINGS_INF, $inputSettings, "update", array("primary_key" => "settings_name"));
}
addNotice("success", $locale['900']);
redirect(FUSION_REQUEST);
} else {
addNotice('danger', $locale['901']);
}
}
echo "<div class='well'>" . $locale['articles_0031'] . "</div>";
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:31,代码来源:article_settings.php
示例9: Copyright
| Copyright (C) 2002 - 2011 Nick Jones
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: permalinks.php
| Author: Ankur Thakur
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "../maincore.php";
pageAccess('PL');
require_once THEMES . "templates/admin_header.php";
include LOCALE . LOCALESET . "admin/settings.php";
include LOCALE . LOCALESET . "admin/permalinks.php";
$settings = fusion_get_settings();
add_breadcrumb(array('link' => ADMIN . 'permalink.php' . $aidlink, 'title' => $locale['428']));
// Check if mod_rewrite is enabled
$mod_rewrite = FALSE;
if (function_exists('apache_get_modules') && in_array('mod_rewrite', apache_get_modules())) {
$mod_rewrite = TRUE;
} elseif (isset($_SERVER['IIS_UrlRewriteModule'])) {
$mod_rewrite = TRUE;
} elseif (isset($_SERVER['MOD_REWRITE'])) {
$mod_rewrite = TRUE;
}
define('MOD_REWRITE', $mod_rewrite);
开发者ID:knapnet,项目名称:PHP-Fusion,代码行数:31,代码来源:permalink.php
示例10: Copyright
| Copyright (C) PHP-Fusion Inc
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: settings_misc.php
| Author: PHP-Fusion Development Team
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "../maincore.php";
pageAccess('S6');
require_once THEMES . "templates/admin_header.php";
include LOCALE . LOCALESET . "admin/settings.php";
add_breadcrumb(array('link' => ADMIN . "settings_misc.php" . $aidlink, 'title' => $locale['misc_settings']));
if (isset($_POST['savesettings'])) {
$inputData = array("tinymce_enabled" => form_sanitizer($_POST['tinymce_enabled'], 0, "tinymce_enabled"), "smtp_host" => form_sanitizer($_POST['smtp_host'], "", "smtp_host"), "smtp_port" => form_sanitizer($_POST['smtp_port'], "", "smtp_port"), "smtp_auth" => isset($_POST['smtp_auth']) && !empty($_POST['smtp_username']) && !empty($_POST['smtp_password']) ? TRUE : FALSE, "smtp_username" => form_sanitizer($_POST['smtp_username'], "", "smtp_username"), "login_method" => form_sanitizer($_POST['login_method'], 0, "login_method"), "thumb_compression" => form_sanitizer($_POST['thumb_compression'], 0, "thumb_compression"), "mime_check" => form_sanitizer($_POST['mime_check'], 0, "mime_check"), "guestposts" => form_sanitizer($_POST['guestposts'], 0, "guestposts"), "comments_enabled" => form_sanitizer($_POST['comments_enabled'], 0, "comments_enabled"), "comments_per_page" => form_sanitizer($_POST['comments_per_page'], 10, "comments_per_page"), "ratings_enabled" => form_sanitizer($_POST['ratings_enabled'], 0, "ratings_enabled"), "visitorcounter_enabled" => form_sanitizer($_POST['visitorcounter_enabled'], 0, "visitorcounter_enabled"), "rendertime_enabled" => form_sanitizer($_POST['rendertime_enabled'], 0, "rendertime_enabled"), "comments_sorting" => form_sanitizer($_POST['comments_sorting'], "DESC", "comments_sorting"), "index_url_bbcode" => form_sanitizer($_POST['index_url_bbcode'], 0, "index_url_bbcode"), "index_url_userweb" => form_sanitizer($_POST['index_url_userweb'], 0, "index_url_userweb"));
if (defender::safe()) {
foreach ($inputData as $settings_name => $settings_value) {
$data = array("settings_name" => $settings_name, "settings_value" => $settings_value);
dbquery_insert(DB_SETTINGS, $data, "update", array("primary_key" => "settings_name"));
}
addNotice('success', $locale['900']);
redirect(FUSION_SELF . $aidlink);
} else {
addNotice('danger', $locale['901']);
}
开发者ID:knapnet,项目名称:PHP-Fusion,代码行数:31,代码来源:settings_misc.php
示例11: Copyright
| Copyright (C) PHP-Fusion Inc
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: images.php
| Author: PHP-Fusion Development Team
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "../maincore.php";
pageAccess('IM');
require_once THEMES . "templates/admin_header.php";
include LOCALE . LOCALESET . "admin/image_uploads.php";
if (isset($_GET['action']) && ($_GET['action'] = "update")) {
include INCLUDES . "buildlist.php";
}
$folders = array("images" => IMAGES, "imagesa" => IMAGES_A, "imagesn" => IMAGES_N, "imagesnc" => IMAGES_NC, "imagesb" => IMAGES_B, "imagesbc" => IMAGES_BC);
if (isset($_GET['ifolder']) && ctype_alnum($_GET['ifolder']) == 1 && isset($folders[$_GET['ifolder']])) {
$_GET['ifolder'] = stripinput($_GET['ifolder']);
$afolder = $folders[$_GET['ifolder']];
} else {
$_GET['ifolder'] = "images";
$afolder = IMAGES;
}
$image_list = makefilelist($afolder, ".|..", TRUE, "files", "php|js|ico|DS_Store|SVN");
if ($image_list) {
开发者ID:knapnet,项目名称:PHP-Fusion,代码行数:31,代码来源:images.php
示例12: Copyright
| Copyright (C) PHP-Fusion Inc
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: polls.php
| Author: PHP-Fusion Development Team
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "../../maincore.php";
pageAccess('PO');
require_once THEMES . "templates/admin_header.php";
if (file_exists(INFUSIONS . "member_poll_panel/locale/" . LOCALESET . "member_poll_panel_admin.php")) {
include INFUSIONS . "member_poll_panel/locale/" . LOCALESET . "member_poll_panel_admin.php";
} else {
include INFUSIONS . "member_poll_panel/locale/English/member_poll_panel_admin.php";
}
add_breadcrumb(array('link' => ADMIN . 'polls.php' . $aidlink, 'title' => $locale['439c']));
if (isset($_GET['poll_id']) && !isnum($_GET['poll_id'])) {
redirect(FUSION_SELF);
}
$poll_option = array();
if (isset($_POST['save'])) {
$poll_title = form_sanitizer($_POST['poll_title'], '', 'poll_title');
$poll_language = form_sanitizer($_POST['poll_language'], "", "poll_language");
foreach ($_POST['poll_option'] as $key => $value) {
开发者ID:knapnet,项目名称:PHP-Fusion,代码行数:31,代码来源:member_poll_panel_admin.php
示例13: Copyright
| Copyright (C) PHP-Fusion Inc
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: settings_languages.php
| Author: PHP-Fusion Development Team
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "../maincore.php";
pageAccess("LANG");
require_once THEMES . "templates/admin_header.php";
$locale = fusion_get_locale('', LOCALE . LOCALESET . 'admin/settings.php');
$locale += fusion_get_locale('', LOCALE . LOCALESET . 'setup.php');
// Just follow the display of the current admin language.
$settings = fusion_get_settings();
if (!empty($locale['setup_3007'])) {
dbquery("UPDATE " . DB_LANGUAGE_TABLES . " SET mlt_title='" . $locale['setup_3007'] . "' WHERE mlt_rights='CP'");
}
if (!empty($locale['setup_3210'])) {
dbquery("UPDATE " . DB_LANGUAGE_TABLES . " SET mlt_title='" . $locale['setup_3210'] . "' WHERE mlt_rights='SL'");
}
if (!empty($locale['setup_3208'])) {
dbquery("UPDATE " . DB_LANGUAGE_TABLES . " SET mlt_title='" . $locale['setup_3208'] . "' WHERE mlt_rights='ET'");
}
if (!empty($locale['setup_3211'])) {
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:31,代码来源:settings_languages.php
示例14: Copyright
| Copyright (C) 2002 - 2011 Nick Jones
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: db_backup.php
| Author: PHP-Fusion Development Team
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "../maincore.php";
pageAccess('DB');
require_once THEMES . "templates/admin_header.php";
include LOCALE . LOCALESET . "admin/db-backup.php";
add_breadcrumb(array('link' => ADMIN . 'db_backup.php' . $aidlink, 'title' => $locale['450']));
function stripsiteinput($text)
{
$search = array("&", """, "'", "\", """, "'", "<", ">", " ");
$replace = array("", "", "", "", "", "", "", "", "");
$text = str_replace($search, $replace, $text);
return $text;
}
if (isset($_POST['btn_create_backup'])) {
$backup_file_name = form_sanitizer($_POST['backup_filename'], '', 'backup_filename');
if (!check_admin_pass(isset($_POST['user_admin_password']) ? form_sanitizer($_POST['user_admin_password'], '', 'user_admin_password') : "")) {
$defender->stop();
}
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:31,代码来源:db_backup.php
示例15: Gaudyn
| Filename: panels.php
| Author: PHP-Fusion Development Team
| Author: Robert Gaudyn (Wooya)
| Author: Joakim Falk (Domi)
| Author: Frederick MC Chan (Hien)
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "../maincore.php";
pageAccess('P');
require_once THEMES . "templates/admin_header.php";
include LOCALE . LOCALESET . "admin/panels.php";
/**
* Class fusion_panels
*/
class fusion_panels
{
/**
* @var array|bool
*/
private $data = array('panel_id' => 0, 'panel_name' => '', 'panel_filename' => '', 'panel_content' => '', 'panel_type' => 'php', 'panel_side' => 1, 'panel_order' => 0, 'panel_access' => 0, 'panel_display' => 0, 'panel_status' => 0, 'panel_url_list' => '', 'panel_restriction' => 3, 'panel_languages' => '');
/**
* @var string
*/
private $formaction = '';
开发者ID:knapnet,项目名称:PHP-Fusion,代码行数:31,代码来源:panels.php
示例16: pageAccess
<?php
pageAccess("N");
/**
* Displays News Listing
*/
function display_news_listing()
{
$aidlink = fusion_get_aidlink();
$locale = fusion_get_locale();
// Run functions
$allowed_actions = array_flip(array("publish", "unpublish", "sticky", "unsticky", "delete"));
if (isset($_POST['table_action']) && isset($allowed_actions[$_POST['table_action']])) {
$input = isset($_POST['news_id']) ? explode(",", form_sanitizer($_POST['news_id'], "", "news_id")) : "";
if (!empty($input)) {
foreach ($input as $news_id) {
// check input table
if (dbcount("('news_id')", DB_NEWS, "news_id='" . intval($news_id) . "'") && defender::safe()) {
switch ($_POST['table_action']) {
case "publish":
dbquery("UPDATE " . DB_NEWS . " SET news_draft='0' WHERE news_id='" . intval($news_id) . "'");
break;
case "unpublish":
dbquery("UPDATE " . DB_NEWS . " SET news_draft='1' WHERE news_id='" . intval($news_id) . "'");
break;
case "sticky":
dbquery("UPDATE " . DB_NEWS . " SET news_sticky='1' WHERE news_id='" . intval($news_id) . "'");
break;
case "unsticky":
dbquery("UPDATE " . DB_NEWS . " SET news_sticky='0' WHERE news_id='" . intval($news_id) . "'");
break;
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:31,代码来源:news.php
示例17: Copyright
| PHP-Fusion Content Management System
| Copyright (C) PHP-Fusion Inc
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: admin/gallery_actions.php
| Author: PHP-Fusion Development Team
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
pageAccess("PH");
if (isset($_POST['cancel'])) {
redirect(FUSION_SELF . $aidlink);
}
/**
* Move up and down album
*/
if (isset($_GET['action']) && ($_GET['action'] == "mu" || $_GET['action'] == "md") && isset($_GET['cat_id']) && isnum($_GET['cat_id']) && isset($_GET['order']) && isnum($_GET['order'])) {
$album_max_order = dbresult(dbquery("SELECT MAX(album_order) FROM " . DB_PHOTO_ALBUMS . " WHERE album_language='" . LANGUAGE . "'"), 0) + 1;
if (dbcount("('album_id')", DB_PHOTO_ALBUMS, "album_id=' " . intval($_GET['cat_id']) . " '")) {
switch ($_GET['action']) {
case "mu":
// -1 album order
if ($_GET['order'] < $album_max_order && $_GET['order'] >= 1) {
dbquery("UPDATE " . DB_PHOTO_ALBUMS . " SET album_order = album_order+1 WHERE album_order='" . $_GET['order'] . "'");
dbquery("UPDATE " . DB_PHOTO_ALBUMS . " SET album_order= '" . $_GET['order'] . "' WHERE album_id ='" . $_GET['cat_id'] . "'");
开发者ID:knapnet,项目名称:PHP-Fusion,代码行数:31,代码来源:gallery_actions.php
示例18: Chan
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: theme.php
| Author: Frederick MC Chan (Hien)
| Co-Author: PHP-Fusion Development Team
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "../maincore.php";
pageAccess('S1');
require_once THEMES . "templates/admin_header.php";
require_once LOCALE . LOCALESET . "admin/theme.php";
$theme_admin = new \PHPFusion\Atom\Admin();
/**
* Auto Upgrade Script -- remove after beta period
*/
if (!db_exists(DB_SETTINGS_THEME)) {
$result = dbquery("CREATE TABLE " . DB_SETTINGS_THEME . "\r\n\t\t(settings_name VARCHAR(200) NOT NULL DEFAULT '',\r\n\t\tsettings_value TEXT NOT NULL,\r\n\t\tsettings_theme VARCHAR(200) NOT NULL DEFAULT '',\r\n\t\tPRIMARY KEY (settings_name)\r\n\t\t) ENGINE=MYISAM DEFAULT CHARSET=UTF8 COLLATE=utf8_unicode_ci\r\n\t");
addNotice('success', "Theme Engine has been upgraded");
}
opentable($locale['theme_1000']);
switch ($_GET['action']) {
case "manage":
if (isset($_GET['theme'])) {
echo "<div class='m-t-20'>\n";
开发者ID:knapnet,项目名称:PHP-Fusion,代码行数:31,代码来源:theme.php
示例19: Copyright
| Copyright (C) PHP-Fusion Inc
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: upgrade.php
| Author: PHP-Fusion Development Team
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "../maincore.php";
pageAccess("U");
require_once THEMES . "templates/admin_header.php";
$settings = fusion_get_settings();
if (file_exists(LOCALE . LOCALESET . "admin/upgrade.php")) {
include LOCALE . LOCALESET . "admin/upgrade.php";
} else {
include LOCALE . "English/admin/upgrade.php";
}
add_breadcrumb(array('link' => ADMIN . 'upgrade.php' . $aidlink, 'title' => $locale['400']));
opentable($locale['400']);
// Execute Gallery migration script if called
if (isset($_GET['migrate_gallery'])) {
require_once ADMIN . "upgrade/gallery_migrate.php";
echo "<div class='well'>Your Photoalbums have been moved</div>";
}
// Execute Forum attachment migration script if called
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:31,代码来源:upgrade.php
示例20: Copyright
| PHP-Fusion Content Management System
| Copyright (C) PHP-Fusion Inc
| https://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: article_cats_admin.php
| Author: PHP-Fusion Development Team
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
pageAccess("A");
if (isset($_GET['action']) && $_GET['action'] == "delete" && (isset($_GET['cat_id']) && isnum($_GET['cat_id']))) {
$result = dbcount("(article_id)", DB_ARTICLES, "article_cat='" . $_GET['cat_id'] . "'") || dbcount("(article_cat_id)", DB_ARTICLE_CATS, "article_cat_parent='" . intval($_GET['cat_id']) . "'");
if (!empty($result)) {
addNotice("danger", $locale['articles_0152'] . " " . $locale['articles_0153']);
redirect(clean_request("cat_view=1", array("section", "aid"), true));
} else {
$result = dbquery("DELETE FROM " . DB_ARTICLE_CATS . " WHERE article_cat_id='" . intval($_GET['cat_id']) . "'");
addNotice("success", $locale['articles_0154']);
redirect(clean_request("cat_view=1", array("section", "aid"), true));
}
} else {
// First Initialize
$cat_id = 0;
$cat_name = "";
$cat_description = "";
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:31,代码来源:article_cat.php
注:本文中的pageAccess函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论