当前位置: 首页>>代码示例>>PHP>>正文


PHP phorum_admin_build_url函数代码示例

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


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

示例1: show

 function show()
 {
     if ($this->_title) {
         echo "<div class=\"PhorumAdminMenuTitle\">{$this->_title}</div>\n";
     }
     echo "<div class=\"PhorumAdminMenu\"";
     if ($this->_id) {
         echo " id=\"{$this->_id}\"";
     }
     echo ">";
     foreach ($this->_links as $link) {
         $desc = htmlspecialchars($link["description"]);
         $href = htmlspecialchars($_SERVER["PHP_SELF"]);
         $title = htmlspecialchars($link["title"]);
         $input_args = array();
         if (!empty($link["module"])) {
             $input_args[] = "module={$link['module']}";
         }
         $url = phorum_admin_build_url($input_args);
         $html = "<a title=\"{$desc}\" href=\"{$url}";
         $html .= "\">{$title}</a><br />";
         echo $html;
     }
     echo "</div>\n";
 }
开发者ID:sleepy909,项目名称:cpassman,代码行数:25,代码来源:PhorumAdminMenu.php

示例2: PhorumInputForm

if (defined("PHORUM_INSTALL")) {
    $frm = new PhorumInputForm("", "post", "Continue ->");
    $frm->addbreak("Optional modules");
    $frm->hidden("module", "install");
    $frm->hidden("sanity_checks_done", "1");
    $frm->hidden("step", "modules");
    $frm->hidden("do_modules_update", "1");
    $frm->addmessage("Phorum has a very robust module system.  The following modules are included with the distribution.  You can find more modules at the Phorum web site.  Some modules may have additional configuration options, which are not available during install.  To configure the modules, click the Modules menu item after installation is done.");
} else {
    $frm = new PhorumInputForm("", "post");
    $frm->addbreak("Phorum Module Settings");
    $frm->hidden("module", "mods");
}
foreach ($list['modules'] as $name => $info) {
    if ($info["settings"] && !defined("PHORUM_INSTALL")) {
        $settings_url = phorum_admin_build_url(array('module=modsettings', "mod={$name}"));
        $settings_link = "<br /><a name=\"link-settings-{$name}\" href=\"{$settings_url}\">Settings</a>";
    } else {
        $settings_link = "";
    }
    $text = $info["title"];
    if (isset($info["version"])) {
        $text .= " (version " . $info["version"] . ")";
    }
    if (isset($info["desc"])) {
        $text .= "<div class=\"small\">" . wordwrap($info["desc"], 90, "<br />") . "</div>";
    }
    if (isset($info["author"])) {
        $text .= "<div class=\"small\">Created by " . $info["author"] . "</div>";
    }
    if (isset($info["release_date"])) {
开发者ID:sleepy909,项目名称:cpassman,代码行数:31,代码来源:mods.php

示例3: foreach

        </tr>
        <tr>
            <td class="PhorumAdminTableHead">Display Name</td>
            <td class="PhorumAdminTableHead">Email</td>
            <td class="PhorumAdminTableHead">Status</td>
            <td class="PhorumAdminTableHead">Posts</td>
            <td class="PhorumAdminTableHead">Last Activity</td>
            <td class="PhorumAdminTableHead">Delete</td>
        </tr>
EOT;
        foreach ($user_ids as $user_id) {
            $user = $users[$user_id];
            $status = $user_status_map[$user['active']];
            $posts = intval($user['posts']);
            $ta_class = "PhorumAdminTableRow" . ($ta_class == "PhorumAdminTableRow" ? "Alt" : "");
            $edit_url = phorum_admin_build_url(array('module=users', 'user_id=' . $user['user_id'], 'edit=1'));
            echo "<tr>\n";
            echo "    <td class=\"" . $ta_class . "\"><a href=\"{$edit_url}\">" . (empty($PHORUM['custom_display_name']) ? htmlspecialchars($user['display_name']) : $user['display_name']) . "</a></td>\n";
            echo "    <td class=\"" . $ta_class . "\">" . htmlspecialchars($user['email']) . "</td>\n";
            echo "    <td class=\"" . $ta_class . "\">{$status}</td>\n";
            echo "    <td class=\"" . $ta_class . "\" style=\"text-align:right\">{$posts}</td>\n";
            echo "    <td class=\"" . $ta_class . "\" align=\"right\">" . (intval($user['date_last_active']) ? phorum_date($PHORUM['short_date'], intval($user['date_last_active'])) : "&nbsp;") . "</td>\n";
            echo "    <td class=\"" . $ta_class . "\"><input type=\"checkbox\" name=\"deleteIds[]\" value=\"{$user['user_id']}\"></td>\n";
            echo "</tr>\n";
        }
        echo <<<EOT
        <tr>
          <td colspan="6" align="right">
          <input type="button" value="Check All"
           onClick="CheckboxControl(this.form, true);">
          <input type="button" value="Clear All"
开发者ID:sleepy909,项目名称:cpassman,代码行数:31,代码来源:users.php

示例4: unset

                if ($_POST[$field] != $PHORUM["display_name_source"]) {
                    $need_display_name_updates = TRUE;
                }
                break;
        }
        if ($error) {
            break;
        }
    }
    if (empty($error)) {
        unset($_POST["module"]);
        unset($_POST["phorum_admin_token"]);
        if ($PHORUM['DB']->update_settings($_POST)) {
            $redir = phorum_admin_build_url(array('module=settings', 'message=success'), TRUE);
            if ($need_display_name_updates) {
                $redir = phorum_admin_build_url(array('module=update_display_names'), TRUE);
            }
            phorum_api_redirect($redir);
            exit;
        } else {
            $error = "Database error while updating settings.";
        }
    }
}
if ($error) {
    phorum_admin_error($error);
} elseif (isset($_GET['message']) && $_GET['message'] == 'success') {
    $okmsg = "Settings updated";
    phorum_admin_okmsg($okmsg);
}
// create the time zone drop down array
开发者ID:netovs,项目名称:Core,代码行数:31,代码来源:settings.php

示例5: defined

        $_POST[$k] = $v;
    }
}
// Are we running in filter mode?
$filter_mode = defined("LOGVIEWER_FILTER_MODE") || isset($_POST["filter_mode"]);
// Some defaults for the page.
$default_pagelength = 20;
$default_loglevel = EVENTLOG_LVL_DEBUG;
// The available page lengths.
$pagelengths = array(10 => "10 events per page", 20 => "20 events per page", 50 => "50 events per page", 100 => "100 events per page", 250 => "250 events per page");
// ----------------------------------------------------------------------
// Build event log filter.
// ----------------------------------------------------------------------
// The base URL for creating URL's to the filter page. This will be used
// later on, for making parts of the output clickable for adjusting the filter.
$filter_base = phorum_admin_build_url(array('module=modsettings', 'mod=event_logging', 'el_action=filter'));
$show_loglevel = array();
$show_categories = array();
$filter = NULL;
if ($filter_mode) {
    $filter = array();
    // What log levels to show?
    // No log level selected at all will show all log levels.
    $loglevels = NULL;
    if (count($_POST)) {
        if (isset($_POST["show_loglevel"])) {
            $show_loglevel = $_POST["show_loglevel"];
            $loglevels = array_keys($show_loglevel);
            foreach ($loglevels as $l) {
                $filter_base .= '&show_loglevel[' . urlencode($l) . ']';
            }
开发者ID:samuell,项目名称:Core,代码行数:31,代码来源:logviewer.php

示例6: phorum_api_forums_by_inheritance

    }
    $frm->addbreak("Inherit Forum Settings");
    // First check if the settings for this forum are inherited by one or
    // more other forums and/or folders. Inherited inheritance is not
    // allowed, so if this is the case, choosing a forum to inherit from
    // is not allowed.
    $disabled_form_input_inherit = '';
    $add_inherit_text = "";
    if ($forum_id) {
        $slaves = phorum_api_forums_by_inheritance($forum_id);
        if (!empty($slaves)) {
            $disabled_form_input_inherit = 'disabled="disabled"';
            $add_inherit_text = "<br />You cannot let this forum inherit its " . "settings from another forum, because the " . "following forums and or folders inherit from " . "the current forum already:<br /><ul>\n";
            foreach ($slaves as $id => $data) {
                array_shift($data['forum_path']);
                $edit_url = phorum_admin_build_url(array('module=edit' . ($data['folder_flag'] ? 'folder' : 'forum'), "forum_id={$id}"));
                $add_inherit_text .= "<li><a href=\"{$edit_url}\">" . implode(" / ", $data['forum_path']) . "</li>\n";
            }
            $add_inherit_text .= "</ul>\n";
        }
    }
    $inherit_id_options = phorum_api_forums_get_inherit_id_options($forum_id);
    $row = $frm->addrow("Inherit the settings below this option from", $frm->select_tag("inherit_id", $inherit_id_options, $inherit_id, $disabled_form_input_inherit) . $add_inherit_text);
}
$frm->addbreak("Moderation / Permissions");
$row = $frm->addrow("Moderate Messages", $frm->select_tag("moderation", array(PHORUM_MODERATE_OFF => "Disabled", PHORUM_MODERATE_ON => "Enabled"), $moderation, $disabled_form_input));
$frm->addhelp($row, "Moderate Messages", "This setting determines whether messages are visible to users immediately after they are posted.  If enabled, all messages will remain hidden until approved by a moderator.");
$frm->addrow("Email Messages To Moderators", $frm->select_tag("email_moderators", array(PHORUM_EMAIL_MODERATOR_OFF => "Disabled", PHORUM_EMAIL_MODERATOR_ON => "Enabled"), $email_moderators, $disabled_form_input));
$pub_perm_frm = $frm->checkbox("pub_perms[" . PHORUM_USER_ALLOW_READ . "]", 1, "Read", $pub_perms & PHORUM_USER_ALLOW_READ, $disabled_form_input) . "&nbsp;&nbsp;" . $frm->checkbox("pub_perms[" . PHORUM_USER_ALLOW_REPLY . "]", 1, "Reply", $pub_perms & PHORUM_USER_ALLOW_REPLY, $disabled_form_input) . "&nbsp;&nbsp;" . $frm->checkbox("pub_perms[" . PHORUM_USER_ALLOW_NEW_TOPIC . "]", 1, "Create&nbsp;New&nbsp;Topics", $pub_perms & PHORUM_USER_ALLOW_NEW_TOPIC, $disabled_form_input) . "<br />" . $frm->checkbox("pub_perms[" . PHORUM_USER_ALLOW_ATTACH . "]", 1, "Attach&nbsp;Files", $pub_perms & PHORUM_USER_ALLOW_ATTACH, $disabled_form_input);
$frm->addrow("Public Anonymous Users", $pub_perm_frm);
$reg_perm_frm = $frm->checkbox("reg_perms[" . PHORUM_USER_ALLOW_READ . "]", 1, "Read", $reg_perms & PHORUM_USER_ALLOW_READ, $disabled_form_input) . "&nbsp;&nbsp;" . $frm->checkbox("reg_perms[" . PHORUM_USER_ALLOW_REPLY . "]", 1, "Reply", $reg_perms & PHORUM_USER_ALLOW_REPLY, $disabled_form_input) . "&nbsp;&nbsp;" . $frm->checkbox("reg_perms[" . PHORUM_USER_ALLOW_NEW_TOPIC . "]", 1, "Create&nbsp;New&nbsp;Topics", $reg_perms & PHORUM_USER_ALLOW_NEW_TOPIC, $disabled_form_input) . "<br />" . $frm->checkbox("reg_perms[" . PHORUM_USER_ALLOW_EDIT . "]", 1, "Edit&nbsp;Their&nbsp;Posts", $reg_perms & PHORUM_USER_ALLOW_EDIT, $disabled_form_input) . "&nbsp;&nbsp;" . $frm->checkbox("reg_perms[" . PHORUM_USER_ALLOW_ATTACH . "]", 1, "Attach&nbsp;Files", $reg_perms & PHORUM_USER_ALLOW_ATTACH, $disabled_form_input) . "<br/>" . $frm->checkbox('allow_email_notify', 1, 'Allow email notification for following topics', $allow_email_notify, $disabled_form_input);
开发者ID:netovs,项目名称:Core,代码行数:31,代码来源:newforum.php

示例7: phorum_db_rebuild_search_data

        $okmsg .= "{$threads_updated} threads updated.<br />";
    }
    if (isset($_POST['rebuild_searchdata']) && !empty($_POST['rebuild_searchdata'])) {
        if (empty($PHORUM['DBCONFIG']['empty_search_table'])) {
            $ret = phorum_db_rebuild_search_data();
            $okmsg .= "Searchdata successfully rebuilt.<br />";
        } else {
            $okmsg .= "<strong>Flag &quot;empty_search_table&quot; set in db configuration. Search table is not going to be rebuild with that.</strong>";
        }
    }
    if (isset($_POST['rebuild_userposts']) && !empty($_POST['rebuild_userposts'])) {
        $ret = phorum_db_rebuild_user_posts();
        $okmsg .= "Postcounts for users updated.<br />";
    }
    if (isset($_POST['rebuild_display_names']) && !empty($_POST['rebuild_display_names'])) {
        $redir_url = phorum_admin_build_url(array('module=update_display_names', 'request=integrity'), TRUE);
        phorum_redirect_by_url($redir_url);
        exit;
    }
    if (isset($_POST['rebuild_forumpaths']) && !empty($_POST['rebuild_forumpaths'])) {
        $forums = phorum_admin_build_path_array();
        unset($forums[0]);
        foreach ($forums as $fid => $forumpath) {
            $update_forum = array('forum_id' => $fid, 'forum_path' => $forumpath);
            phorum_db_update_forum($update_forum);
        }
        $okmsg .= "Forum paths successfully rebuilt.<br />";
    }
}
if ($error) {
    phorum_admin_error($error);
开发者ID:mgs2,项目名称:kw-forum,代码行数:31,代码来源:rebuild.php

示例8: PhorumInputForm

    }
    $frm->show();
}
if (empty($_REQUEST["edit"])) {
    $frm = new PhorumInputForm("", "post");
    $frm->addbreak("Phorum Group Admin");
    $frm->hidden("module", "groups");
    $frm->hidden("section", "add");
    $frm->addrow("Add A Group:", $frm->text_box("group_name", "", 50));
    $frm->show();
    $frm_url = phorum_admin_build_url();
    echo "<hr class=\"PhorumAdminHR\" />";
    echo "<form action=\"{$frm_url}\" method=\"post\">\n";
    echo "<input type=\"hidden\" name=\"phorum_admin_token\" value=\"{$PHORUM['admin_token']}\">\n";
    echo "<input type=\"hidden\" name=\"module\" value=\"groups\">\n";
    echo "<input type=\"hidden\" name=\"action\" value=\"deleteGroups\">\n";
    echo "<table border=\"0\" cellspacing=\"1\" cellpadding=\"0\" class=\"PhorumAdminTable\" width=\"100%\">\n";
    echo "<tr>\n";
    echo "    <td class=\"PhorumAdminTableHead\">Group</td>\n";
    echo "    <td class=\"PhorumAdminTableHead\">Delete</td>\n";
    echo "</tr>\n";
    foreach ($groups as $group) {
        $edit_url = phorum_admin_build_url(array('module=groups', 'edit=1', 'group_id=' . $group['group_id']));
        echo "<tr>\n";
        echo "    <td class=\"PhorumAdminTableRow\"><a href=\"{$edit_url}\">" . htmlspecialchars($group['name']) . "</a></td>\n";
        echo "    <td class=\"PhorumAdminTableRow\">Delete? <input type=\"checkbox\" name=\"deleteIds[]\" value=\"{$group['group_id']}\"></td>\n";
        echo "</tr>\n";
    }
    echo "<tr><td colspan=\"2\" align=\"right\"><input type=\"submit\" name=\"submit\" value=\"Delete Selected\"></td></tr>";
    echo "</table></form>\n";
}
开发者ID:netovs,项目名称:Core,代码行数:31,代码来源:groups.php

示例9: unset

unset($get['module']);
unset($get['phorum_admin_token']);
if (empty($post) && empty($get)) {
    $module = '';
    if (isset($_POST['module'])) {
        $module = basename($_POST['module']);
    } elseif (isset($_GET['module'])) {
        $module = basename($_GET['module']);
    }
    $url = phorum_admin_build_url('module=' . urlencode($module));
    phorum_redirect_by_url($url);
}
$targetargs = $_SERVER['QUERY_STRING'];
$target_html = htmlspecialchars(phorum_admin_build_url($targetargs));
$targs_html = htmlspecialchars($targetargs);
$post_url = phorum_admin_build_url('base');
?>
You are accessing the admin after a security timeout.<br /><br />
The requested URL was: 
<pre><?php 
echo $target_html;
?>
</pre><br />
<strong>Please make sure that you really want to access this URL and weren't tricked to go to the admin.</strong><br />
Please click on <strong>continue</strong> to go to this URL or on <strong>cancel</strong> to go to the forum homepage.
<br /><br />
<form action="<?php 
echo $post_url;
?>
" method="POST">
<input type="hidden" name="module" value="tokenmissing" />
开发者ID:sleepy909,项目名称:cpassman,代码行数:31,代码来源:tokenmissing.php

示例10: phorum_api_user_authenticate

require_once PHORUM_PATH . '/include/api/sign.php';
if (isset($_POST["username"]) && isset($_POST["password"])) {
    $user_id = phorum_api_user_authenticate(PHORUM_ADMIN_SESSION, trim($_POST["username"]), trim($_POST["password"]));
    if ($user_id && phorum_api_user_set_active_user(PHORUM_ADMIN_SESSION, $user_id) && phorum_api_user_session_create(PHORUM_ADMIN_SESSION)) {
        // update the token and time
        $GLOBALS["PHORUM"]["user"]['settings_data']['admin_token_time'] = time();
        $sig_data = $GLOBALS["PHORUM"]["user"]['user_id'] . time() . $GLOBALS["PHORUM"]["user"]['username'];
        $GLOBALS["PHORUM"]["user"]['settings_data']['admin_token'] = phorum_api_sign($sig_data);
        $GLOBALS["PHORUM"]['admin_token'] = $GLOBALS["PHORUM"]["user"]['settings_data']['admin_token'];
        $tmp_user = array('user_id' => $GLOBALS["PHORUM"]["user"]['user_id'], 'settings_data' => $GLOBALS["PHORUM"]["user"]['settings_data']);
        phorum_api_user_save($tmp_user);
        if (!empty($_POST["target"])) {
            $target_url = phorum_admin_build_url($_POST['target'], TRUE);
            phorum_api_redirect($target_url);
        } else {
            $redir_url = phorum_admin_build_url(NULL, TRUE);
            phorum_api_redirect($redir_url);
        }
        exit;
    } else {
        /**
         * TODO Move to User API.
         */
        phorum_api_hook("failed_login", array("username" => $_POST["username"], "password" => $_POST["password"], "location" => "admin"));
    }
}
require_once './include/admin/PhorumInputForm.php';
$frm = new PhorumInputForm("", "post");
if (!empty($_SERVER["QUERY_STRING"])) {
    $frm->hidden("target", htmlspecialchars($_SERVER["QUERY_STRING"], ENT_COMPAT, $PHORUM["DATA"]['CHARSET']));
}
开发者ID:samuell,项目名称:Core,代码行数:31,代码来源:login.php

示例11: phorum_admin_set_vroot

            }
        } else {
            // just default root ...
            phorum_admin_set_vroot($cur_folder_id, 0, $cur_folder_id);
        }
        // done with vroots
        phorum_db_drop_folder($cur_folder_id);
        $msg = "The folder was deleted.  All forums and folders in this folder have been moved to this folder's parent.";
    } else {
        phorum_db_drop_forum($_GET["forum_id"]);
        $msg = "The forum was deleted.  All messages in that forum were deleted.";
    }
} elseif ($_GET["confirm"] == "No") {
    $msg = "No action was taken.";
} else {
    $forums = phorum_db_get_forums((int) $_GET["forum_id"]);
    $forum = array_shift($forums);
    if ($forum["folder_flag"]) {
        $msg = "Are you sure you want to delete {$forum['name']}?  All forums and folders in this folder will be moved to this folder's parent.";
    } else {
        $msg = "Are you sure you want to delete {$forum['name']}?  All messages in this forum will be deleted";
    }
    $frm_url = phorum_admin_build_url('base');
    $msg .= "<form action=\"{$frm_url}\" method=\"get\"><input type=\"hidden\" name=\"phorum_admin_token\" value=\"{$PHORUM['admin_token']}\"><input type=\"hidden\" name=\"module\" value=\"{$module}\" /><input type=\"hidden\" name=\"forum_id\" value=\"{$forum['forum_id']}\" /><input type=\"hidden\" name=\"folder_flag\" value=\"{$forum['folder_flag']}\" /><input type=\"submit\" name=\"confirm\" value=\"Yes\" />&nbsp;<input type=\"submit\" name=\"confirm\" value=\"No\" /></form>";
}
?>
<div class="PhorumInfoMessage"><?php 
echo $msg;
?>
</div>
开发者ID:sleepy909,项目名称:cpassman,代码行数:30,代码来源:deleteforum.php

示例12: implode

            $elts[] = "<a href=\"{$elturl}\">{$name}</a>";
        }
    }
    $path = implode(' / ', $elts);
} else {
    $path = '<strong>Root folder</strong>';
}
?>

<div class="PhorumAdminTitle">
  Forum and folder settings
</div>

<div class="PhorumAdminBreadcrumbs">
  <?php 
if (empty($folder['forum_id'])) {
    print "<span class=\"icon-folder\"></span>";
} else {
    $upurl = phorum_admin_build_url(array('module=default', "parent_id={$parent_parent_id}"));
    print "<a href=\"{$upurl}\"><span class=\"icon-folder-up\"></span></a>";
}
echo "{$path}";
?>
</div>

<table border="0" cellspacing="2" cellpadding="3" width="100%">
<?php 
echo $rows;
?>
</table>
开发者ID:samuell,项目名称:Core,代码行数:30,代码来源:default.php

示例13: min

    if ($perc > 100) {
        $perc = 100;
    }
    ?>

    <strong>Running display name updates.</strong><br/>
    <strong>This might take a while ...</strong><br/><br/>
    <table><tr><td>
    <div style="height:20px;width:300px; border:1px solid black">
    <div style="height:20px;width:<?php 
    print $perc;
    ?>
%;background-color:green">
    </div></div></td><td style="padding-left:10px">
      <?php 
    $update_count = min(($batch + 1) * $batchsize, $user_count);
    print "{$update_count} users of {$user_count} updated";
    ?>
    </td></tr></table> <?php 
    $redir = phorum_admin_build_url(array('module=update_display_names', "batch=" . ($batch + 1), 'step=2', 'user_count=' . $user_count), TRUE);
    ?>

    <script type="text/javascript">
    window.onload = function () {
        document.location.href = '<?php 
    print addslashes($redir);
    ?>
';
    }
    </script> <?php 
}
开发者ID:mgs2,项目名称:kw-forum,代码行数:31,代码来源:update_display_names.php

示例14: elseif

$frm->addbreak("Log settings");
if (!file_exists('./mods/event_logging')) {
    $check = '<span style="color:red">The Event Logging module ' . 'is currently not installed; logging cannot ' . 'be enabled</span>';
    $disabled = 'disabled="disabled"';
    $PHORUM["mod_spamhurdles"]["log_events"] = 0;
} elseif (empty($PHORUM['mods']['event_logging'])) {
    $check = '<span style="color:red">The Event Logging module ' . 'is currently not activated; logging cannot ' . 'be enabled</span>';
    $disabled = 'disabled="disabled"';
    $PHORUM["mod_spamhurdles"]["log_events"] = 0;
} else {
    $check = '<span style="color:darkgreen">The Event Logging module ' . 'is activated; events can be logged by enabling the ' . 'feature below</span>';
    $disabled = '';
}
$frm->addrow($check, '');
$row = $frm->addrow('Log blocked form posts to the Event Logging module?', $frm->checkbox("log_events", 1, "Yes", $PHORUM["mod_spamhurdles"]["log_events"], $disabled));
$url = phorum_admin_build_url(array('module=modsettings', 'mod=event_logging', 'el_action=logviewer'));
$frm->addhelp($row, "Log blocked form posts to the Event Logging module?", "When both this feature and the Event Logging module are enabled,\n     then the Spam Hurdles module will log information about blocked\n     form posts to the Phorum Event Log. To view this log, go to\n     <a href=\"{$url}\">the Event Log viewer</a>");
// ----------------------------------------------------------------------
// Configure spam hurdles for posting messages
// ----------------------------------------------------------------------
$frm->addbreak("Spam Hurdles for posting new messages");
$row = $frm->addrow('What action has to be taken when a spam message is suspected?', $frm->select_tag('posting_block_action', array('blockerror' => 'Fully block and show an error', 'unapprove' => 'Accept, but make unapproved'), $PHORUM['mod_spamhurdles']['posting']['block_action']));
$frm->addhelp($row, "Action when a spam message is suspected", "You can choose whether you want to fully block suspected spam messages\n     or that you want to have them posted in a moderated state, so they\n     will need approval by a moderator.<br/>\n     <br/>\n     A message is suspicious if it fails one of the spam hurdles:<br/>\n     <ul>\n       <li>Block forms that are submitted multiple times</li>\n       <li>Check if an HTML commented form field is submitted</li>\n       <li>Let the browser sign the form using JavaScript</li>\n     </ul>\n     For the remaining hurdles, an error state might be resolved by\n     the user (e.g. by filling in the correct CAPTCHA code or by\n     resubmitting a too quickly posted form). For those errors,\n     there will always be an error message and a chance for the\n     user to fix the issue to make posting possible.");
create_spamhurdle_options($frm, 'posting', array('posting.tpl', 'posting_messageform.tpl'), 'tpl_editor_before_textarea', array("none" => "Disable hurdle", "anonymous" => "Enable for anonymous users", "all" => "Enable for all users"));
// ----------------------------------------------------------------------
// Configure spam hurdles for user registration
// ----------------------------------------------------------------------
$frm->addbreak("Spam Hurdles for user registration");
create_spamhurdle_options($frm, 'register', array('register.tpl'), 'tpl_register_form', array("none" => "Disable hurdle", "all" => "Enable hurdle"));
// ----------------------------------------------------------------------
// Configure spam hurdles for PM
开发者ID:netovs,项目名称:Core,代码行数:31,代码来源:settings.php

示例15: list

        list($dummy, $upgrade) = each($upgrades);
        $message = phorum_dbupgrade_run($upgrade);
        // Show the results.
        $frm = new PhorumInputForm("", "post", "Continue -&gt;");
        $frm->addbreak("Upgrading Phorum (multiple steps possible) ...");
        $w = floor($index / $count * 100);
        $frm->addmessage('<table><tr><td>' . '<div style="height:20px;width:300px; border:1px solid black">' . '<div style="height:20px;width:' . $w . '%; background-color:green">' . '</div></div></td><td style="padding-left:10px">' . 'upgrade ' . $index . " of " . $count . '</td></tr></table>');
        $frm->addmessage($message);
        $frm->hidden("step", 1);
        $frm->hidden("module", "upgrade");
        $frm->hidden("is_module_upgrade", $is_module_upgrade);
        $frm->hidden("upgradeindex", $index);
        $frm->hidden("upgradecount", $count);
        $frm->show();
        break;
        // Step 2: the upgrade has been completed.
    // Step 2: the upgrade has been completed.
    case 2:
        // Show the results.
        $base_url = phorum_admin_build_url();
        $frm = new PhorumInputForm("", "post", "Finish");
        $frm->addbreak("The upgrade is complete");
        $frm->addmessage("You may want to look through the " . "<a href=\"{$base_url}\">the admin interface</a> " . "for any new features in this version.");
        $frm->show();
        break;
        // Safety net for illegal step values.
    // Safety net for illegal step values.
    default:
        print "Internal error: illegal upgrading step " . htmlspecialchars($step) . " requested.";
        return;
}
开发者ID:samuell,项目名称:Core,代码行数:31,代码来源:upgrade.php


注:本文中的phorum_admin_build_url函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。