• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP stripslash函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中stripslash函数的典型用法代码示例。如果您正苦于以下问题:PHP stripslash函数的具体用法?PHP stripslash怎么用?PHP stripslash使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了stripslash函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: showRatings

function showRatings($post, $userfrom, $userto, $wrapper = true)
{
    global $ratingsExist;
    $types = dbquery("select * from " . DB_PREFIX . "fb_rate_type");
    if ($userfrom !== $userto && dbrows($types)) {
        if ($wrapper) {
            echo "<div style='float:right;' id='rb_" . $post . "'>";
        }
        echo "<span id='ratename{$post}' class='small'></span>&nbsp;\n";
        while ($type = dbarray($types)) {
            if (!dbrows(dbquery("select * from " . DB_PREFIX . "fb_rate where rate_type='" . $type['type_id'] . "' and rate_user='{$userto}' and rate_post='{$post}' and rate_by='{$userfrom}'"))) {
                echo "<span onMouseOver='document.getElementById(\"ratename{$post}\").innerHTML=\"" . stripslash($type['type_name']) . "\";' onMouseOut='document.getElementById(\"ratename{$post}\").innerHTML=\" \"' onClick='giveRating({$post}, {$userfrom}, {$userto}, " . $type['type_id'] . ");'><img src='" . INFUSIONS . "fusionboard4/images/forum_icons/" . $type['type_icon'] . "' alt='" . stripslash($type['type_name']) . "' title='" . stripslash($type['type_name']) . "' style='vertical-align:middle;cursor:pointer;' /></span>\n";
            }
        }
        if ($wrapper) {
            echo "</div>\n";
        }
    }
}
开发者ID:simplyianm,项目名称:clububer,代码行数:19,代码来源:rating.inc.php


示例2: post_ratings_do

function post_ratings_do($post, $userfrom, $userto, $wrapper = true)
{
    global $post_rating_type_cache;
    #, $post_rating_cache;
    $res = '';
    if (!$post_rating_type_cache) {
        cache_post_ratings_type();
    }
    if ($userfrom !== $userto && is_array($post_rating_type_cache) && count($post_rating_type_cache)) {
        if ($wrapper) {
            $res .= "<div style='float:right;' id='rb_" . $post . "'>";
        }
        $res .= "<span id='ratename{$post}' class='small'></span>&nbsp;\n";
        foreach ($post_rating_type_cache as $type) {
            if (!dbrows(dbquery("SELECT * from " . DB_POST_RATINGS . " where rate_type='" . $type['type_id'] . "' and rate_user='{$userto}' and rate_post='{$post}' and rate_by='{$userfrom}'"))) {
                $res .= "<span onMouseOver='document.getElementById(\"ratename{$post}\").innerHTML=\"" . stripslash(parseubb($type['type_name'])) . "\";' onMouseOut='document.getElementById(\"ratename{$post}\").innerHTML=\" \"' onclick='giveRating({$post}, {$userfrom}, {$userto}, " . $type['type_id'] . ");'><img src='" . IMAGES . "forum_post_ratings/" . $type['type_icon'] . "' alt='" . stripslash(parseubb($type['type_name'])) . "' title='" . stripslash(parseubb($type['type_name'])) . "' style='vertical-align:middle;cursor:pointer;' /></span>\n";
            }
        }
        if ($wrapper) {
            $res .= "</div>\n";
        }
    }
    return $res;
}
开发者ID:MichaelFichtner,项目名称:RadioLaFamilia,代码行数:24,代码来源:forum_post_rating.php


示例3: dbarray

     if (dbrows($titleLookup)) {
         $titleData = dbarray($titleLookup);
         $title .= "<b>" . stripslash($titleData['title_title']) . "</b>";
     } else {
         $title .= "<b>" . stripslash($data['user_title']) . "</b>";
     }
     if ($settings['forum_ranks'] || $fb4['show_ulevel']) {
         $title .= " :: ";
     }
 }
 echo "</span><br /><br />\n";
 renderAwards($data['user_id'], "", "<br /><br />");
 echo "<!--forum_thread_user_info--><span class='small'><strong>" . $locale['502'] . "</strong> " . $data['user_posts'] . "</span><br />\n";
 echo "<span class='small'><strong>" . $locale['504'] . "</strong> " . showdate("%d.%m.%y", $data['user_joined']) . "</span>\n";
 if ($data['user_location']) {
     echo "<br /><span class='small'><strong>" . $locale['fb500'] . ":</strong> " . stripslash($data['user_location']) . "</span>\n";
 }
 if ($data['user_birthdate'] !== "0000-00-00") {
     $birthday = explode("-", $data['user_birthdate']);
     $age = strftime("%Y") - $birthday[0];
     if (strftime("%m") < $birthday[1]) {
         $age--;
     } elseif (strftime("%m") == $birthday[1]) {
         if (strftime("%d") < $birthday[2]) {
             $age--;
         }
     }
     echo "<br /><span class='small'><strong>" . $locale['fb512'] . "</strong> {$age}</span>\n";
 }
 echo showWarning($data['user_id']);
 echo "<br /></td>";
开发者ID:simplyianm,项目名称:clububer,代码行数:31,代码来源:hybrid.php


示例4: dbquery

    $error = 0;
    $result = dbquery("UPDATE " . DB_SETTINGS . " SET settings_value='" . addslash($_POST['sitebanner1']) . "' WHERE settings_name='sitebanner1'");
    if (!$result) {
        $error = 1;
    }
    $result = dbquery("UPDATE " . DB_SETTINGS . " SET settings_value='" . addslash($_POST['sitebanner2']) . "' WHERE settings_name='sitebanner2'");
    if (!$result) {
        $error = 1;
    }
    redirect(FUSION_SELF . $aidlink . "&error=" . $error, TRUE);
}
if (isset($_POST['preview_banners'])) {
    $sitebanner1 = "";
    $sitebanner2 = "";
    $sitebanner1 = stripslash($_POST['sitebanner1']);
    $sitebanner2 = stripslash($_POST['sitebanner2']);
} else {
    $sitebanner1 = stripslashes($settings['sitebanner1']);
    $sitebanner2 = stripslashes($settings['sitebanner2']);
}
opentable($locale['850']);
echo openform("banner_form", "post", FUSION_REQUEST);
echo form_textarea('sitebanner1', $locale['851'], $sitebanner1, array("type" => "html", "form_name" => "banner_form", "inline" => FALSE));
if (isset($_POST['preview_banners']) && $sitebanner1) {
    eval("?><div class='list-group-item'>" . $sitebanner1 . "</div><?php ");
}
echo form_textarea('sitebanner2', $locale['852'], $sitebanner2, array("type" => "html", "form_name" => "banner_form", "inline" => FALSE));
if (isset($_POST['preview_banners']) && $sitebanner2) {
    eval("?><div class='list-group-item'>" . $sitebanner2 . "</div><?php ");
}
echo form_button('preview_banners', $locale['855'], $locale['855'], array('class' => 'btn-default m-r-10'));
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:31,代码来源:banners.php


示例5: author

| 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";
require_once THEMES . "templates/admin_header.php";
include LOCALE . LOCALESET . "admin/settings.php";
if (!checkrights("S1") || !defined("iAUTH") || $_GET['aid'] != iAUTH) {
    redirect("../index.php");
}
if (isset($_POST['savesettings'])) {
    $error = 0;
    $siteintro = descript(stripslash($_POST['intro']));
    $sitefooter = descript(stripslash($_POST['footer']));
    $localeset = stripinput($_POST['localeset']);
    $old_localeset = stripinput($_POST['old_localeset']);
    $result = dbquery("UPDATE " . DB_SETTINGS . " SET\n\t\tsitename='" . stripinput($_POST['sitename']) . "',\n\t\tsiteurl='" . stripinput($_POST['siteurl']) . (strrchr($_POST['siteurl'], "/") != "/" ? "/" : "") . "',\n\t\tsitebanner='" . stripinput($_POST['sitebanner']) . "',\n\t\tsiteemail='" . stripinput($_POST['siteemail']) . "',\n\t\tsiteusername='" . stripinput($_POST['username']) . "',\n\t\tsiteintro='" . addslashes(addslashes($siteintro)) . "',\n\t\tdescription='" . stripinput($_POST['description']) . "',\n\t\tkeywords='" . stripinput($_POST['keywords']) . "',\n\t\tfooter='" . addslashes(addslashes($sitefooter)) . "',\n\t\topening_page='" . stripinput($_POST['opening_page']) . "',\n\t\tnews_style='" . (isnum($_POST['news_style']) ? $_POST['news_style'] : "0") . "',\n\t\tlocale='{$localeset}',\n\t\ttheme='" . stripinput($_POST['theme']) . "',\n\t\tdefault_search='" . stripinput($_POST['default_search']) . "',\n\t\texclude_left='" . stripinput($_POST['exclude_left']) . "',\n\t\texclude_upper='" . stripinput($_POST['exclude_upper']) . "',\n\t\texclude_lower='" . stripinput($_POST['exclude_lower']) . "',\n\t\texclude_right='" . stripinput($_POST['exclude_right']) . "'\n\t");
    if (!$result) {
        $error = 1;
    }
    if ($localeset != $old_localeset && !$error) {
        include LOCALE . $localeset . "/admin/main.php";
        $result = dbquery("UPDATE " . DB_ADMIN . " SET admin_title='" . $locale['201'] . "' WHERE admin_link='administrators.php'");
        if (!$result) {
            $error = 1;
        }
        $result = dbquery("UPDATE " . DB_ADMIN . " SET admin_title='" . $locale['202'] . "' WHERE admin_link='article_cats.php'");
        if (!$result) {
            $error = 1;
开发者ID:edwintcloud,项目名称:mycms,代码行数:31,代码来源:settings_main.php


示例6: stripinput

function stripinput($text)
{
    if (!is_array($text)) {
        $text = stripslash(trim($text));
        $text = preg_replace("/(&amp;)+(?=\\#([0-9]{2,3});)/i", "&", $text);
        $search = array("&", "\"", "'", "\\", '\\"', "\\'", "<", ">", "&nbsp;");
        $replace = array("&amp;", "&quot;", "&#39;", "&#92;", "&quot;", "&#39;", "&lt;", "&gt;", " ");
        $text = str_replace($search, $replace, $text);
    } else {
        foreach ($text as $key => $value) {
            $text[$key] = stripinput($value);
        }
    }
    return $text;
}
开发者ID:WuChEn,项目名称:PHP-Fusion,代码行数:15,代码来源:maincore.php


示例7: closetable

    }
    echo "<td colspan='2' align='center' class='tbl'><input type='submit' class='button' name='ads_save' value='" . $locale['ads_save'] . "' /></td></tr>\n";
    echo "</table>\n";
    echo "</form>\n";
    closetable();
} elseif ($_GET['page'] == 2) {
    if (isset($_POST['ads_save'])) {
        $error = 0;
        if (check_admin_pass(isset($_POST['admin_password']) ? stripinput($_POST['admin_password']) : "")) {
            if (!set_mainsetting('ads_in_name', stripinput($_POST['ads_in_name']))) {
                $error = 1;
            }
            if (!set_mainsetting('ads_in_show', isnum($_POST['ads_in_show']) ? $_POST['ads_in_show'] : "0")) {
                $error = 1;
            }
            if (!set_mainsetting('ads_in_code', addslashes(stripslash($_POST['ads_in_code'])))) {
                $error = 1;
            }
            log_admin_action("admin-3", "admin_adssystem_in_save");
            set_admin_pass(isset($_POST['admin_password']) ? stripinput($_POST['admin_password']) : "");
            redirect(FUSION_SELF . $aidlink . "&amp;page=2&amp;error=" . $error);
        } else {
            redirect(FUSION_SELF . $aidlink . "&amp;page=2&amp;error=2");
        }
    }
    opentable($locale['ads_title']);
    echo $navigation;
    echo "<form name='ads_form' method='post' action='" . FUSION_SELF . $aidlink . "&amp;page=2'>\n";
    echo "<table cellpadding='0' cellspacing='0' width='450' align='center'>\n";
    echo "<tr>\n";
    echo "<td class='tbl'>" . $locale['ads_name'] . "</td>";
开发者ID:MichaelFichtner,项目名称:RadioLaFamilia,代码行数:31,代码来源:advertising_system.php


示例8: dbquery

             $forum_description = $data['forum_description'];
             $forum_cat = $data['forum_cat'];
             $forum_access = $data['forum_access'];
             $forum_post = $data['forum_post'];
             $forum_reply = $data['forum_reply'];
             $forum_attach = $data['forum_attach'];
             $forum_poll = $data['forum_poll'];
             $forum_vote = $data['forum_vote'];
             $forum_title = $locale['501'];
             $forum_action = FUSION_SELF . $aidlink . "&section=forums&amp;action=edit&amp;forum_id=" . $data['forum_id'] . "&amp;t=forum";
             $cat_title = $locale['400'];
             $cat_action = FUSION_SELF . $aidlink . "&section=forums";
             $fbResult = dbquery("select * from " . $db_prefix . "fb_forums where forum_id='" . $_GET['forum_id'] . "'");
             if (dbrows($fbResult)) {
                 $fbData = dbarray($fbResult);
                 $forum_icon = stripslash($fbData['forum_icon']);
                 $forum_parent = $fbData['forum_parent'];
             } else {
                 $fbQuery = dbquery("insert into " . $db_prefix . "fb_forums (forum_id, forum_icon) VALUES('" . $_GET['forum_id'] . "', '')");
                 $forum_icon = "";
                 $forum_parent = "";
             }
         } else {
             redirect(FUSION_SELF . $aidlink . "&section=forums");
         }
     }
 } else {
     $cat_name = "";
     $cat_order = "";
     $cat_title = $locale['400'];
     $cat_action = FUSION_SELF . $aidlink . "&section=forums";
开发者ID:simplyianm,项目名称:clububer,代码行数:31,代码来源:forumadmin.php


示例9: author

| 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";
require_once THEMES . "templates/header.php";
include LOCALE . LOCALESET . "contact.php";
add_to_title($locale['global_200'] . $locale['400']);
if (isset($_POST['sendmessage'])) {
    $error = "";
    $mailname = isset($_POST['mailname']) ? substr(stripinput(trim($_POST['mailname'])), 0, 50) : "";
    $email = isset($_POST['email']) ? substr(stripinput(trim($_POST['email'])), 0, 100) : "";
    $subject = isset($_POST['subject']) ? substr(str_replace(array("\r", "\n", "@"), "", descript(stripslash(trim($_POST['subject'])))), 0, 50) : "";
    $message = isset($_POST['message']) ? descript(stripslash(trim($_POST['message']))) : "";
    if ($mailname == "") {
        $error .= " <span class='alt'>" . $locale['420'] . "</span><br />\n";
    }
    if ($email == "" || !preg_match("/^[-0-9A-Z_\\.]{1,50}@([-0-9A-Z_\\.]+\\.){1,50}([0-9A-Z]){2,4}\$/i", $email)) {
        $error .= " <span class='alt'>" . $locale['421'] . "</span><br />\n";
    }
    if ($subject == "") {
        $error .= " <span class='alt'>" . $locale['422'] . "</span><br />\n";
    }
    if ($message == "") {
        $error .= " <span class='alt'>" . $locale['423'] . "</span><br />\n";
    }
    $_CAPTCHA_IS_VALID = false;
    include INCLUDES . "captchas/" . $settings['captcha'] . "/captcha_check.php";
    if ($_CAPTCHA_IS_VALID == false) {
开发者ID:dioda,项目名称:phpfusion,代码行数:31,代码来源:contact.php


示例10: dbarray

         $data = dbarray($result);
     }
     $result = dbquery("DELETE FROM " . DB_CUSTOM_PAGES . " WHERE page_id='" . $_POST['page_id'] . "'");
     $result = dbquery("DELETE FROM " . DB_SITE_LINKS . " WHERE link_url='viewpage.php?page_id=" . $_POST['page_id'] . "'");
     if ($settings['enable_tags']) {
         delete_tags($_POST['page_id'], "C");
     }
     // Pimped: tag
     log_admin_action("admin-1", "admin_custompage_deleted", "", "", $data['page_title'] . " (ID: " . $_POST['page_id'] . ")");
     redirect(FUSION_SELF . $aidlink . "&status=del");
 } else {
     if (isset($_POST['preview'])) {
         $addlink = isset($_POST['add_link']) ? " checked='checked'" : "";
         $page_title = stripinput($_POST['page_title']);
         $page_access = $_POST['page_access'];
         $page_content = stripslash($_POST['page_content']);
         $page_keywords = $_POST['page_keywords'];
         // meta
         $comments = isset($_POST['page_comments']) ? " checked='checked'" : "";
         $ratings = isset($_POST['page_ratings']) ? " checked='checked'" : "";
         if (check_admin_pass(isset($_POST['admin_password']) ? stripinput($_POST['admin_password']) : "")) {
             log_admin_action("admin-1", "admin_custompage_preview", "", "", $page_title);
             opentable($page_title);
             eval("?>" . $page_content . "<?php ");
             closetable();
             set_admin_pass(isset($_POST['admin_password']) ? stripinput($_POST['admin_password']) : "");
         } else {
             echo "<div id='close-message'><div class='admin-message'>" . $locale['global_182'] . "</div></div>\n";
         }
         $page_content = phpentities($page_content);
     }
开发者ID:MichaelFichtner,项目名称:RadioLaFamilia,代码行数:31,代码来源:custom_pages.php


示例11: stripinput

/**
 * Strip Input Function, prevents HTML in unwanted places
 * @param string|string[] $text
 * @return string|string[]
 */
function stripinput($text)
{
    if (!is_array($text)) {
        return str_replace('\\', '&#092;', htmlspecialchars(stripslash(trim($text)), ENT_QUOTES));
    }
    foreach ($text as $i => $item) {
        $text[$i] = stripinput($item);
    }
    return $text;
}
开发者ID:php-fusion,项目名称:PHP-Fusion,代码行数:15,代码来源:core_functions_include.php


示例12: redirect

        }
    } else {
        redirect(FUSION_SELF . $aidlink . "&status=pw");
    }
} else {
    if (isset($_POST['delete']) && (isset($_POST['page_id']) && isnum($_POST['page_id']))) {
        $result = dbquery("DELETE FROM " . DB_CUSTOM_PAGES . " WHERE page_id='" . $_POST['page_id'] . "'");
        $result = dbquery("DELETE FROM " . DB_SITE_LINKS . " WHERE link_url='viewpage.php?page_id=" . $_POST['page_id'] . "'");
        redirect(FUSION_SELF . $aidlink . "&status=del");
    } else {
        if (isset($_POST['preview'])) {
            $addlink = isset($_POST['add_link']) ? " checked='checked'" : "";
            $page_title = stripinput($_POST['page_title']);
            $page_access = $_POST['page_access'];
            $page_content = stripslash($_POST['page_content']);
            $page_language = stripslash($_POST['page_language']);
            $comments = isset($_POST['page_comments']) ? " checked='checked'" : "";
            $ratings = isset($_POST['page_ratings']) ? " checked='checked'" : "";
            if (check_admin_pass(isset($_POST['admin_password']) ? stripinput($_POST['admin_password']) : "")) {
                opentable($page_title);
                echo "<div class='panel panel-default'>\n";
                echo "<div class='panel-body'>\n";
                eval("?>" . $page_content . "<?php ");
                echo "</div>\n</div>\n";
                closetable();
                set_admin_pass(isset($_POST['admin_password']) ? stripinput($_POST['admin_password']) : "");
            } else {
                echo "<div id='close-message'><div class='admin-message alert alert-info m-t-10'>" . $locale['global_182'] . "</div></div>\n";
            }
            $page_content = phpentities($page_content);
        }
开发者ID:WuChEn,项目名称:PHP-Fusion,代码行数:31,代码来源:custom_pages.php


示例13: opentable

        $type_icon = "";
        $action = FUSION_SELF . $aidlink . "&section=ratings";
        $panel = $locale['fb851'];
        $button = $locale['fb853'];
    }
    opentable($panel);
    $iconOpts = makefileopts(makefilelist(INFUSIONS . "fusionboard4/images/forum_icons/", ".|..|index.php|Thumbs.db"), $type_icon);
    echo "<form action='{$action}' name='ratingForm' method='post'>\n\t\t<table width='300' cellspacing='1' cellpadding='0' class='tbl-border center'>\n\t\t<tr>\n\t\t\t<td class='tbl1'>" . $locale['fb855'] . "</td>\n\t\t\t<td class='tbl2'><input type='text' name='type_name' class='textbox' value='{$type_name}'></td>\n\t\t</tr>\n\t\t<tr>\n\t\t\t<td class='tbl1'>" . $locale['fb856'] . "</td>\n\t\t\t<td class='tbl2'><select name='type_icon' class='textbox'>\n\t\t\t{$iconOpts}\n\t\t\t</select></td>\n\t\t</tr>\n\t\t<tr>\n\t\t\t<td class='tbl1' colspan='2' style='text-align:center;'>\n\t\t\t<input type='submit' name='goRating' value='{$button}' class='button'>\n\t\t\t</td>\n\t\t</tr>\n\t\t</table>\n\t\t</form>\n";
    closetable();
    tablebreak();
    opentable($locale['fb860']);
    $result = dbquery("select * from " . DB_PREFIX . "fb_rate_type");
    if (dbrows($result)) {
        echo "<table width='300' cellspacing='1' cellpadding='0' class='tbl-border center'>\n\t\t\t<tr>\n\t\t\t\t<td class='tbl2' style='font-weight:bold;'>" . $locale['fb855'] . "</td>\n\t\t\t\t<td class='tbl2' style='font-weight:bold;'>" . $locale['fb856'] . "</td>\n\t\t\t\t<td class='tbl2' style='font-weight:bold;'>" . $locale['fb857'] . "</td>\n\t\t\t</tr>\n";
        while ($data = dbarray($result)) {
            echo "<tr>\n\t\t\t\t\t<td class='tbl1'>" . stripslash($data['type_name']) . "</td>\n\t\t\t\t\t<td class='tbl1'><img src='" . INFUSIONS . "fusionboard4/images/forum_icons/" . $data['type_icon'] . "' alt=''></td>\n\t\t\t\t\t<td class='tbl1'><a href='" . FUSION_SELF . $aidlink . "&amp;section=ratings&amp;edit=" . $data['type_id'] . "'>" . $locale['fb858'] . "</a> :: \n\t\t\t\t\t<a href='" . FUSION_SELF . $aidlink . "&amp;section=ratings&amp;del=" . $data['type_id'] . "' onclick=\"return confirm('" . $locale['fb869'] . "');\">" . $locale['fb859'] . "</a></td>\n\t\t\t\t</tr>\n";
        }
        echo "</table>\n";
    } else {
        echo "<div align='center'>" . $locale['fb861'] . "</div>\n";
    }
    closetable();
} elseif ($_GET['section'] == "forums") {
    include INFUSIONS . "fusionboard4/includes/forumadmin.php";
} elseif ($_GET['section'] == "warnings") {
    if (isset($_POST['goRule']) && isNum($_GET['level']) && isset($_GET['level'])) {
        $pm = isset($_POST['rule_pm']) ? addslash(stripinput($_POST['rule_pm'])) : "";
        $email = isset($_POST['rule_email']) ? addslash(stripinput($_POST['rule_email'])) : "";
        $bantime = isset($_POST['rule_bantime']) && isNum($_POST['rule_bantime']) ? $_POST['rule_bantime'] : 0;
        $perma = isset($_POST['rule_perma']) && isNum($_POST['rule_perma']) ? $_POST['rule_perma'] : 0;
        $result = dbquery("update " . DB_PREFIX . "fb_warn_rules set rule_pm='{$pm}', rule_email='{$email}', rule_bantime='{$bantime}', rule_perma='{$perma}' where rule_level='" . $_GET['level'] . "'");
开发者ID:simplyianm,项目名称:clububer,代码行数:31,代码来源:admin.php


示例14: elseif

if (isset($_GET['error']) && (isnum($_GET['error']) or $_GET['error'] == "pw") && !isset($message)) {
    if ($_GET['error'] == "0") {
        $message = $locale['900'];
    } elseif ($_GET['error'] == "1") {
        $message = $locale['901'];
    } elseif ($_GET['error'] == "pw") {
        $message = "Admin-Password incorrect";
    }
    if (isset($message)) {
        echo "<div id='close-message'><div class='admin-message'>" . $message . "</div></div>\n";
    }
}
if (isset($_POST['savesettings'])) {
    if (check_admin_pass(isset($_POST['admin_password']) ? stripinput($_POST['admin_password']) : "")) {
        $error = 0;
        if (!set_mainsetting('siteintro', addslashes(descript(stripslash($_POST['intro']))))) {
            $error = 1;
        }
        if (!set_mainsetting('siteintro_collapse', isset($_POST['siteintro_collapse']) ? "1" : "0")) {
            $error = 1;
        }
        if (!set_mainsetting('siteintro_collapse_state', isset($_POST['siteintro_collapse_state']) ? "on" : "off")) {
            $error = 1;
        }
        if (!set_mainsetting('welome_panel_dis', isnum($_POST['welome_panel_dis']) ? $_POST['welome_panel_dis'] : "0")) {
            $error = 1;
        }
        set_admin_pass(isset($_POST['admin_password']) ? stripinput($_POST['admin_password']) : "");
        log_admin_action("admin-1", "admin_wel_panel_edited");
        redirect(FUSION_SELF . $aidlink . "&error=" . $error);
    } else {
开发者ID:MichaelFichtner,项目名称:RadioLaFamilia,代码行数:31,代码来源:welcome_panel.php


示例15: opentable

/*
 * GUI
 */
opentable($locale['PRP800']);
prp_admin_menu();
if (isset($_GET['edit']) || isset($_GET['new'])) {
    if (isset($id)) {
        $query_id = dbquery("SELECT license_id, license_text," . " license_name" . " FROM " . DB_PRP_LICENSES . "" . " WHERE license_id='{$id}'");
        $data = dbarray($query_id);
        $action = FUSION_SELF . "?id={$id}";
    } else {
        $data['license_text'] = "";
        $data['license_name'] = "";
        $action = FUSION_SELF;
    }
    echo "<form action='{$action}' method='POST'>\n<div align='center'>\n" . $locale['PRP002'] . ": <input type='text' value='" . $data['license_name'] . "'" . " size='40' maxlength='255' name='name' class='textbox'>\n<p>\n<textarea cols='70' rows='15' class='textbox' name='text'>" . phpentities(stripslash($data['license_text'])) . "</textarea>\n<p>\n<input type='submit' value='" . $locale['PRP010'] . "' class='button' name='save'>\n</div>\n<hr>\n</form>\n";
}
/*
 * show all
 */
$query_id = dbquery("SELECT CHAR_LENGTH(license_text) AS length," . " license_id, license_name" . " FROM " . DB_PRP_LICENSES . "" . " ORDER BY license_name ASC");
if (dbrows($query_id)) {
    echo "<table align='center' cellspacing='1' class='tbl-border'>\n<thead>\n<tr>\n\t<th class='tbl2' width='16'></th>\n\t<th class='tbl2' width='150'>" . $locale['PRP002'] . " [<a href='" . FUSION_SELF . "?new=1'>" . $locale['prp_new'] . "]</a></th>\n\t<th class='tbl2'>" . $locale['PRP801'] . "</th>\n\t<th class='tbl2' colspan='2'># " . $locale['prp_reviews'] . "</th>\n\t<th class='tbl2' width='16'></th>\n</tr>\n</thead>\n<tbody>";
} else {
    if (!isset($_GET['new'])) {
        fallback(FUSION_SELF . "?new=1");
    }
    echo "<p>" . $locale['PRP802'];
}
$lcount = 0;
while ($data = dbarray($query_id)) {
开发者ID:simplyianm,项目名称:clububer,代码行数:31,代码来源:licenses.php


示例16: dbquery

 $result = dbquery("SELECT\n\t\t\tts.submit_datestamp, ts.submit_criteria, tu.user_id, tu.user_name, tu.user_avatar, tu.user_status\n\t\t\tFROM " . DB_SUBMISSIONS . " ts\n\t\t\tLEFT JOIN " . DB_USERS . " tu ON ts.submit_user=tu.user_id\n\t\t\tWHERE submit_type='b' order by submit_datestamp desc");
 if (dbrows($result) > 0) {
     $data = dbarray($result);
     $submit_criteria = unserialize($data['submit_criteria']);
     $callback_data = array("blog_start" => $data['submit_datestamp'], "blog_datestamp" => $data['submit_datestamp'], "blog_keywords" => $submit_criteria['blog_keywords'], "blog_visibility" => 0, "blog_image" => $submit_criteria['blog_image'], "blog_image_t1" => $submit_criteria['blog_image_t1'], "blog_image_t2" => $submit_criteria['blog_image_t2'], "blog_ialign" => $submit_criteria['blog_ialign'], "blog_end" => "", "blog_draft" => 0, "blog_sticky" => 0, "blog_language" => $submit_criteria['blog_language'], "blog_subject" => $submit_criteria['blog_subject'], "blog_cat" => $submit_criteria['blog_cat'], "blog_blog" => phpentities(stripslashes($submit_criteria['blog_blog'])), "blog_extended" => phpentities(stripslashes($submit_criteria['blog_body'])), "blog_breaks" => fusion_get_settings("tinyce_enabled") ? TRUE : FALSE);
     add_to_title($locale['global_200'] . $locale['503'] . $locale['global_201'] . $callback_data['blog_subject'] . "?");
     if (isset($_POST['preview'])) {
         $blog_blog = "";
         if ($_POST['blog_blog']) {
             $blog_blog = phpentities(stripslash($_POST['blog_blog']));
             $blog_blog = str_replace("src='" . str_replace("../", "", IMAGES_B), "src='" . IMAGES_B, stripslash($_POST['blog_blog']));
         }
         $blog_extended = "";
         if ($_POST['blog_extended']) {
             $blog_extended = phpentities(stripslash($_POST['blog_extended']));
             $blog_extended = str_replace("src='" . str_replace("../", "", IMAGES_B), "src='" . IMAGES_B, stripslash($_POST['blog_extended']));
         }
         $callback_data = array("blog_subject" => form_sanitizer($_POST['blog_subject'], '', 'blog_subject'), "blog_cat" => isnum($_POST['blog_cat']) ? $_POST['blog_cat'] : 0, "blog_language" => form_sanitizer($_POST['blog_language'], '', 'blog_language'), "blog_blog" => form_sanitizer($blog_blog, "", "blog_blog"), "blog_extended" => form_sanitizer($blog_extended, "", "blog_extended"), "blog_keywords" => form_sanitizer($_POST['blog_keywords'], '', 'blog_keywords'), "blog_start" => isset($_POST['blog_start']) && $_POST['blog_start'] ? $_POST['blog_start'] : '', "blog_end" => isset($_POST['blog_end']) && $_POST['blog_end'] ? $_POST['blog_end'] : '', "blog_visibility" => isnum($_POST['blog_visibility']) ? $_POST['blog_visibility'] : "0", "blog_draft" => isset($_POST['blog_draft']) ? TRUE : FALSE, "blog_sticky" => isset($_POST['blog_sticky']) ? TRUE : FALSE, "blog_datestamp" => $callback_data['blog_datestamp'], "blog_ialign" => isset($_POST['blog_ialign']) ? $_POST['blog_ialign'] : '', "blog_image" => isset($_POST['blog_image']) ? $_POST['blog_image'] : '', "blog_image_t1" => isset($_POST['blog_image_t1']) ? $_POST['blog_image_t1'] : "", "blog_image_t2" => isset($_POST['blog_image_t2']) ? $_POST['blog_image_t2'] : "");
         $callback_data['blog_breaks'] = "";
         if (isset($_POST['blog_breaks'])) {
             $callback_data['blog_breaks'] = TRUE;
             $callback_data['blog_blog'] = nl2br($callback_data['blog_blog']);
             if ($callback_data['blog_extended']) {
                 $callback_data['blog_extended'] = nl2br($callback_data['blog_extended']);
             }
         }
         if (defender::safe()) {
             echo openmodal('blog_preview', $locale['blog_0141']);
             echo "<h3>" . $callback_data['blog_subject'] . "</h3>\n";
             echo $callback_data['blog_blog'];
             echo "<hr/>\n";
开发者ID:knapnet,项目名称:PHP-Fusion,代码行数:31,代码来源:blog_submissions.php


示例17: showcomments

     		if($data['group_moderate']){
     			echo "<tr>\n<td class='tbl2 navsection'>".$locale['uc370']."</td>\n</tr>\n<tr>\n<td class='tbl1' style='padding:6px;'>\n";
     			
     			echo "</td>\n</tr>\n";
     		}
     		*/
     if ($data['group_wall']) {
         include INFUSIONS . "fusionboard4/includes/comments_enhanced.php";
         echo "<tr>\n<td class='tbl2 navsection'>" . $locale['uc280'] . "</td>\n</tr>\n<tr>\n<td class='tbl2' style='padding:6px;'>\n";
         showcomments("G", DB_USER_GROUPS, "group_id", $_GET['view'], FUSION_SELF . "?section=groups&amp;view=" . $_GET['view'], $in_group);
         echo "</td>\n</tr>\n";
     }
 } else {
     echo "<tr>\n<td class='tbl2 navtitle'>" . stripslash($data['group_name']) . "</td>\n</tr>\n";
     echo "<tr>\n<td class='tbl1'><div style='float:right;'>" . $locale['uc278'] . "<b>" . ($data['group_access'] == "1" ? $locale['uc269'] : ($data['group_access'] == "2" ? $locale['uc270'] : $locale['uc291'])) . "</b></div>\n";
     echo "<span style='font-size:18px;'>" . stripslash($data['group_name']) . "</span><br />\n";
     echo $locale['uc276'] . "<a href='" . BASEDIR . "profile.php?lookup=" . $data['user_id'] . "'>" . $data['user_name'] . "</a><br /><br />\n";
     echo $locale['uc290'] . "</td>\n</tr>\n";
 }
 echo "<tr>\n<td class='tbl2 small' align='center'>";
 $invited = dbcount("(invite_to)", DB_PREFIX . "fb_invites", "invite_to='" . $userdata['user_id'] . "' and invite_group='" . $data['group_id'] . "'");
 if ($in_group) {
     if ($userdata['user_id'] !== $data['group_leader']) {
         echo "<a href='" . FUSION_SELF . "?section=groups&amp;leave=" . $data['group_id'] . "'>" . $locale['uc287'] . "</a> :: \n";
     }
     echo "<a href='" . FUSION_SELF . "?section=groups&amp;members=" . $data['group_id'] . "'>" . $locale['uc288'] . "</a>\n";
 } elseif ($invited) {
     echo "<a href='" . FUSION_SELF . "?section=groups&amp;acceptinvite=" . $data['group_id'] . "'>" . $locale['uc330'] . "</a>\n";
 } elseif ($data['group_access'] == "1") {
     echo "<a href='" . FUSION_SELF . "?section=groups&amp;join=" . $data['group_id'] . "'>" . $locale['uc286'] . "</a>\n";
     // join group
开发者ID:simplyianm,项目名称:clububer,代码行数:31,代码来源:groups.php


示例18: stripslash

function stripslash($var)
{
    if (is_array($var)) {
        foreach ($var as $k => $v) {
            $result[$k] = stripslash($v);
        }
    }
    if (is_string($var)) {
        $result = stripslashes($var);
    }
    return $result ? $result : $var;
}
开发者ID:qinquanxing,项目名称:huaxia,代码行数:12,代码来源:function.common.php


示例19: showtitle

 function showtitle($user)
 {
     global $db_prefix;
     $titleLookup = dbquery("select * from " . DB_PREFIX . "fb_titles where title_id='" . $user['user_title'] . "' and (" . useraccess_better("title_access", $user) . ")");
     if (dbrows($titleLookup)) {
         $titleData = dbarray($titleLookup);
         $title = stripslash($titleData['title_title']);
     } else {
         $title = stripslash($user['user_title']);
     }
     return $title;
 }
开发者ID:simplyianm,项目名称:clububer,代码行数:12,代码来源:func.php


示例20: redirect

                break;
        }
    }
    if ($message) {
        echo "<div id='close-message'><div class='admin-message'>" . $message . "</div></div>\n";
    }
}
if (isset($_POST['save_ro 

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP stripslashes函数代码示例发布时间:2022-05-23
下一篇:
PHP stripsearchkey函数代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap