Exemplo n.º 1
0
function phorum_cc_get_template_info()
{
    $langs = phorum_get_template_info();
    $profile = $GLOBALS['PHORUM']['DATA']['PROFILE'];
    $f_langs = array();
    if (!isset($profile['user_template'])) {
        $defsel = " selected=\"selected\"";
    } else {
        $defsel = "";
    }
    $f_langs[] = array('file' => '', 'name' => $GLOBALS['PHORUM']['DATA']['LANG']['Default'], 'sel' => $defsel);
    foreach ($langs as $entry => $name) {
        $sel = "";
        if (isset($profile['user_template']) && $profile['user_template'] == $entry) {
            $sel = " selected=\"selected\"";
        }
        $f_langs[] = array('file' => $entry, 'name' => $name, 'sel' => $sel);
    }
    return $f_langs;
}
Exemplo n.º 2
0
        }
    }
    if ($vroot == $forum_id) {
        $vroot = 1;
    } else {
        $foreign_vroot = $vroot;
        $vroot = 0;
    }
} else {
    $frm->hidden("module", "newfolder");
    $title = "Add A Folder";
    $folders = $folder_data;
    $vroot = 0;
    $active = 1;
    $template = $PHORUM["default_forum_options"]["template"];
}
$frm->hidden("folder_flag", "1");
$frm->addbreak($title);
$frm->addrow("Folder Title", $frm->text_box("name", $name, 30));
$frm->addrow("Folder Description", $frm->textarea("description", $description, $cols = 60, $rows = 10, "style=\"width: 100%;\""), "top");
$frm->addrow("Folder", $frm->select_tag("parent_id", $folders, $parent_id));
$frm->addrow("Visible", $frm->select_tag("active", array("No", "Yes"), $active));
$frm->addbreak("Display Settings");
$frm->addrow("Template", $frm->select_tag("template", phorum_get_template_info(), $template));
$frm->addrow("Language", $frm->select_tag("language", phorum_get_language_info(), $language));
$frm->addrow("Virtual Root for descending forums/folders", $frm->checkbox("vroot", "1", "enabled", $vroot ? 1 : 0));
if ($foreign_vroot > 0) {
    $frm->addrow("This folder is in the Virtual Root of:", $folders[$foreign_vroot]);
}
phorum_hook("admin_editfolder_form", $frm, $forum_settings);
$frm->show();
Exemplo n.º 3
0
    }
}
$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));
$row = $frm->addrow("Allow Email Notification for following topics", $frm->select_tag("allow_email_notify", array("No", "Yes"), $allow_email_notify, $disabled_form_input));
$frm->addhelp($row, "Allow Email Notification", "This option determines if it is possible for users to use email notification when following topics within this forum.<br/><br/>This does not only apply to enabling email notification at post time, but it also applies to clicking on \"" . $PHORUM["DATA"]["LANG"]["FollowThread"] . "\" from the message read page and to managing subscriptions from the user control center.");
$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 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);
$row = $frm->addrow("Registered Users", $reg_perm_frm);
$frm->addhelp($row, "Registered Users", "These settings do not apply to users that are granted permissions directly via the user admin or via a group permissions.");
$frm->addbreak("Display Settings");
$frm->addrow("Fixed Display-Settings (user can't override them)", $frm->select_tag("display_fixed", array("No", "Yes"), $display_fixed, $disabled_form_input));
$frm->addrow("Template", $frm->select_tag("template", phorum_get_template_info(), $template, $disabled_form_input));
$frm->addrow("Language", $frm->select_tag("language", phorum_get_language_info(), $language, $disabled_form_input));
$frm->addrow("List View", $frm->select_tag("threaded_list", array("Flat", "Threaded"), $threaded_list, $disabled_form_input));
$frm->addrow("Read View", $frm->select_tag("threaded_read", array("Flat", "Threaded", "Hybrid"), $threaded_read, $disabled_form_input));
$frm->addrow("Reverse Threading", $frm->select_tag("reverse_threading", array("No", "Yes"), $reverse_threading, $disabled_form_input));
$frm->addrow("Move Threads On Reply", $frm->select_tag("float_to_top", array("No", "Yes"), $float_to_top, $disabled_form_input));
$frm->addrow("Message List Length (Flat Mode)", $frm->text_box("list_length_flat", $list_length_flat, 10, false, false, $disabled_form_input));
$frm->addrow("Message List Length (Threaded Mode, Nr. of Threads)", $frm->text_box("list_length_threaded", $list_length_threaded, 10, false, false, $disabled_form_input));
$frm->addrow("Read Page Length", $frm->text_box("read_length", $read_length, 10, false, false, $disabled_form_input, $disabled_form_input));
$frm->addrow("Display IP Addresses <small>(note: admins always see it)</small>", $frm->select_tag("display_ip_address", array("No", "Yes"), $display_ip_address, $disabled_form_input));
$frm->addrow("Count views", $frm->select_tag("count_views", array(0 => "No", 1 => "Yes, show views added to subject", 2 => "Yes, show views as extra column"), $count_views, $disabled_form_input));
$row = $frm->addrow("Count views per thread for non-threaded list views", $frm->select_tag("count_views_per_thread", array(0 => "No", 1 => "Yes"), $count_views_per_thread, $disabled_form_input));
$frm->addhelp($row, "Count views per thread for non-threaded list", "By default, Phorum only counts views per message. While this is okay\n     for a forum that runs in threaded view (since there you will always\n     show only one message at a time), it might not work well for forums\n     that run in a non-threaded view (there only one message will get\n     its view count updated, although multiple messages might show).\n     Additionally, if the list view is flat and the read view is threaded, the\n     view count on the list view will only show how often the first message\n     in the thread was viewed.<br/>\n     <br/>\n     With this option enabled, a separate view counter will be updated\n     for the full thread when viewing any of the read pages for that thread.\n     For non-threaded list views, this counter will then be used as the view\n     count for the thread. Note that this does require an extra SQL query\n     to update the separate counter, so on very busy servers you might not\n     want to enable this option.");
$frm->addbreak("Posting Settings");
$frm->addrow("Check for Duplicates", $frm->select_tag("check_duplicate", array("No", "Yes"), $check_duplicate, $disabled_form_input));
$frm->addbreak("Attachment Settings");
Exemplo n.º 4
0
$frm->addhelp($row, "&nbsp;&nbsp;&nbsp;Allow Off Site Links", "You may not want to allow other web sites to link to files that users upload to your forums.  If not, set this to No.  If you want to use links on other parts of your web site or only specific web sites, you will need to use your web server's security features to accomplish this.  For Apache users, you can reference <i>Prevent \"Image Theft\"</i> at http://httpd.apache.org/docs/env.html#examples." );

$row=$frm->addrow( "Private Messaging:", $frm->select_tag( "enable_pm", array( "Off", "On" ), $PHORUM["enable_pm"] ) );

$row=$frm->addrow( "&nbsp;&nbsp;&nbsp;Count New Private Messages", $frm->select_tag( "enable_new_pm_count", array( "No", "Yes" ), $PHORUM["enable_new_pm_count"] ) );
$frm->addhelp($row, "Count New Private Messages", "By setting this to Yes, Phorum will check if a user has new private messages, and display an indicator. On a Phorum with a lot of users and private messages, this may hurt performance. This option has no effect if Private Messaging is disabled." );

$row=$frm->addrow( "&nbsp;&nbsp;&nbsp;Enable Drop-down User List", $frm->select_tag( "enable_dropdown_userlist", array( "No", "Yes" ), $PHORUM["enable_dropdown_userlist"] ) );
$frm->addhelp($row, "Enable Drop-down User List", "By setting this to Yes, Phorum will display a drop-down list of users instead of an empty text box on pages where you can select a user. Two examples of such pages are when sending a private message, and when adding users to a group in the group moderation page. This option should be disabled if you have a large number of users, as a list of thousands of users will slow performance dramatically." );

$row=$frm->addrow( "&nbsp;&nbsp;&nbsp;Max number of stored messages", $frm->text_box( "max_pm_messagecount", $PHORUM["max_pm_messagecount"], 30 ) );
$frm->addhelp($row, "Max number of stored messages", "This is the maximum number of private messages that a user may store on the server. The number of private messages is the total of all messages in all PM folders together. Setting this value to zero will allow for unlimited messages.");

$frm->addbreak( "General Defaults" );

$row=$frm->addrow( "Default Template", $frm->select_tag( "default_template", phorum_get_template_info(), $PHORUM["default_template"] ) );

$row=$frm->addrow( "Default Language", $frm->select_tag( "default_language", phorum_get_language_info(), $PHORUM["default_language"] ) );

$frm->addbreak( "System Email Settings" );

$row=$frm->addrow( "System Emails From Name", $frm->text_box( "system_email_from_name", $PHORUM["system_email_from_name"], 30 ) );

$row=$frm->addrow( "System Emails From Address", $frm->text_box( "system_email_from_address", $PHORUM["system_email_from_address"], 30 ) );

$row=$frm->addrow( "Use BCC in sending mails:", $frm->select_tag( "use_bcc", array( "No", "Yes" ), $PHORUM["use_bcc"] ) );

$row=$frm->addrow( "Ignore Admin for moderator-emails:", $frm->select_tag( "email_ignore_admin", array( "No", "Yes" ), $PHORUM["email_ignore_admin"] ) );
$frm->addhelp($row, "&nbsp;&nbsp;&nbsp;Ignore Admin for moderator-emails", "If you select yes for this option, then the moderator-notifications and report-message emails will not be sent to the admininistrator, only to moderators" );

// calling mods