echo "                        <td align=\"left\" class=\"posthead\">", form_radio("merge_type", 2, gettext("Re-order posts into date order"), false), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                        <td align=\"left\">", form_checkbox("merge_thread_con", "Y", gettext("Confirm")), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" colspan=\"2\"><hr /></td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"260\">", form_radio("thread_merge_split", 1, gettext("Split thread at post:"), false, false, 'posthead'), "</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array('split_thread', $thread_available_pids), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                        <td align=\"left\" class=\"posthead\">", form_radio("split_type", 0, gettext("Selected post and replies only"), false), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                        <td align=\"left\" class=\"posthead\">", form_radio("split_type", 1, gettext("Selected and all following posts"), false), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                        <td align=\"left\">", form_checkbox("split_thread_con", "Y", gettext("Confirm")), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
Example #2
0
echo "                                              <table border=\"0\" width=\"100%\">\n";
echo "                                                <tr>\n";
echo "                                                  <td align=\"left\" width=\"50%\">", form_radio('show_results', POLL_SHOW_RESULTS, gettext("Yes"), isset($show_results) ? $show_results == POLL_SHOW_RESULTS : true), "</td>\n";
echo "                                                  <td align=\"left\" width=\"50%\">", form_radio('show_results', POLL_HIDE_RESULTS, gettext("No"), isset($show_results) ? $show_results == POLL_HIDE_RESULTS : false), "</td>\n";
echo "                                                </tr>\n";
echo "                                              </table>\n";
echo "                                            </td>\n";
echo "                                          </tr>\n";
echo "                                          <tr>\n";
echo "                                            <td align=\"left\">&nbsp;</td>\n";
echo "                                          </tr>\n";
echo "                                          <tr>\n";
echo "                                            <td align=\"left\">", gettext("When would you like your poll to automatically close?"), "</td>\n";
echo "                                          </tr>\n";
echo "                                          <tr>\n";
echo "                                            <td align=\"left\">", form_dropdown_array('close_poll', array(gettext("One day"), gettext("Three days"), gettext("Seven days"), gettext("Thirty days"), gettext("Never")), isset($close_poll) ? $close_poll : 4), "</td>\n";
echo "                                          </tr>\n";
echo "                                          <tr>\n";
echo "                                            <td align=\"left\">&nbsp;</td>\n";
echo "                                          </tr>\n";
echo "                                        </table>\n";
echo "                                      </td>\n";
echo "                                    </tr>\n";
echo "                                  </table>\n";
echo "                                </div>\n";
echo "                              </td>\n";
echo "                            </tr>\n";
echo "                            <tr>\n";
echo "                              <td>\n";
echo "                                <table border=\"0\" cellspacing=\"0\" width=\"100%\">\n";
echo "                                  <tr>\n";
echo "                        <td align=\"left\" colspan=\"2\">&nbsp;</td>\n";
echo "                      </tr>\n";
echo "                      <tr>\n";
echo "                        <td align=\"left\" width=\"270\">", gettext("Attachment Dir"), ":</td>\n";
echo "                        <td align=\"left\">", form_input_text("attachment_dir", isset($forum_global_settings['attachment_dir']) ? htmlentities_array($forum_global_settings['attachment_dir']) : "attachments", 35, 255), "</td>\n";
echo "                      </tr>\n";
echo "                      <tr>\n";
echo "                        <td align=\"left\" width=\"270\">", gettext("Allowed attachment mime-types"), ":</td>\n";
echo "                        <td align=\"left\">", form_input_text("attachment_mime_types", isset($forum_global_settings['attachment_mime_types']) ? htmlentities_array($forum_global_settings['attachment_mime_types']) : '', 35), "&nbsp;</td>\n";
echo "                      </tr>\n";
echo "                      <tr>\n";
echo "                        <td align=\"left\" colspan=\"2\">&nbsp;</td>\n";
echo "                      </tr>\n";
echo "                      <tr>\n";
echo "                        <td align=\"left\" width=\"270\">", gettext("Attachment thumbnail method"), ":</td>\n";
echo "                        <td align=\"left\">", form_dropdown_array('attachment_thumbnail_method', $attachment_thumbnail_methods, isset($forum_global_settings['attachment_thumbnail_method']) ? $forum_global_settings['attachment_thumbnail_method'] : ATTACHMENT_THUMBNAIL_PHPGD), "</td>\n";
echo "                      </tr>\n";
echo "                      <tr>\n";
echo "                        <td align=\"left\" width=\"270\">", gettext("Path to Imagemagick convert binary"), ":</td>\n";
echo "                        <td align=\"left\">", form_input_text("attachment_imagemagick_path", isset($forum_global_settings['attachment_imagemagick_path']) ? htmlentities_array($forum_global_settings['attachment_imagemagick_path']) : '', 35, 255), "</td>\n";
echo "                      </tr>\n";
echo "                      <tr>\n";
echo "                        <td align=\"left\" colspan=\"2\">&nbsp;</td>\n";
echo "                      </tr>\n";
echo "                      <tr>\n";
echo "                        <td align=\"left\" width=\"270\">", gettext("Attachment space per user"), ":</td>\n";
echo "                        <td align=\"left\">", form_input_text("attachments_max_user_space", isset($forum_global_settings['attachments_max_user_space']) ? htmlentities_array($forum_global_settings['attachments_max_user_space'] / 1024 / 1024) : "1", 10, 32), "&nbsp;(MB)</td>\n";
echo "                      </tr>\n";
echo "                      <tr>\n";
echo "                        <td align=\"left\" width=\"270\">", gettext("Attachment space per post"), ":</td>\n";
echo "                        <td align=\"left\">", form_input_text("attachments_max_post_space", isset($forum_global_settings['attachments_max_post_space']) ? htmlentities_array($forum_global_settings['attachments_max_post_space'] / 1024 / 1024) : "1", 10, 32), "&nbsp;(MB)</td>\n";
Example #4
0
echo "  <table cellpadding=\"0\" cellspacing=\"0\" width=\"86%\">\n";
echo "    <tr>\n";
echo "      <td align=\"left\">\n";
echo "        <table class=\"box\" width=\"100%\">\n";
echo "          <tr>\n";
echo "            <td align=\"left\" class=\"posthead\">\n";
echo "              <table class=\"posthead\" width=\"100%\">\n";
echo "                <tr>\n";
echo "                  <td align=\"left\" class=\"subhead\">", gettext("Prune Log"), "</td>\n";
echo "                </tr>\n";
echo "                <tr>\n";
echo "                  <td align=\"center\">\n";
echo "                    <table class=\"posthead\" width=\"95%\">\n";
echo "                      <tr>\n";
echo "                        <td align=\"left\" width=\"250\" style=\"white-space: nowrap\">", gettext("Remove Entries Relating to Action"), ":</td>\n";
echo "                        <td align=\"left\">", form_dropdown_array('remove_type', $admin_log_type_array), "</td>\n";
echo "                      </tr>\n";
echo "                      <tr>\n";
echo "                        <td align=\"left\" width=\"250\" style=\"white-space: nowrap\">", gettext("Remove Entries Older Than (Days)"), ":</td>\n";
echo "                        <td align=\"left\">", form_input_text('remove_days', '30', 15, 4), "&nbsp;", form_submit("prune_log", gettext("Prune Log")), "</td>\n";
echo "                      </tr>\n";
echo "                      <tr>\n";
echo "                        <td align=\"left\">&nbsp;</td>\n";
echo "                      </tr>\n";
echo "                    </table>\n";
echo "                  </td>\n";
echo "                </tr>\n";
echo "              </table>\n";
echo "            </td>\n";
echo "          </tr>\n";
echo "        </table>\n";
Example #5
0
 echo "          <tr>\n";
 echo "            <td align=\"left\" class=\"posthead\">\n";
 echo "              <table width=\"100%\">\n";
 echo "                <tr>\n";
 echo "                  <td class=\"subhead\" align=\"left\">", gettext("Options"), "</td>\n";
 echo "                </tr>\n";
 echo "                <tr>\n";
 echo "                  <td align=\"center\">\n";
 echo "                    <table class=\"posthead\" width=\"95%\">\n";
 echo "                      <tr>\n";
 if (forum_get_setting('require_user_approval', 'Y')) {
     echo "                        <td align=\"left\" valign=\"top\" style=\"white-space: nowrap\">", gettext("With selected"), ":&nbsp;</td>\n";
     echo "                        <td align=\"left\" valign=\"top\" style=\"white-space: nowrap\" width=\"100%\">", form_dropdown_array("action", array(-1 => '&nbsp;', ADMIN_USER_OPTION_END_SESSION => gettext("End Session (Kick)"), ADMIN_USER_OPTION_APPROVE => gettext("Approve")), false, false, 'bhlogondropdown'), "&nbsp;", form_submit("select_action", gettext("Go")), "</td>\n";
 } else {
     echo "                        <td align=\"left\" valign=\"top\" style=\"white-space: nowrap\">", gettext("With selected"), ":&nbsp;</td>\n";
     echo "                        <td align=\"left\" valign=\"top\" style=\"white-space: nowrap\" width=\"100%\">", form_dropdown_array("action", array(-1 => '&nbsp;', ADMIN_USER_OPTION_END_SESSION => gettext("End Session (Kick)")), false, false, 'bhlogondropdown'), "&nbsp;", form_submit("select_action", gettext("Go")), "</td>\n";
 }
 echo "                      </tr>\n";
 echo "                    </table>\n";
 echo "                  </td>\n";
 echo "                </tr>\n";
 echo "                <tr>\n";
 echo "                  <td align=\"left\" colspan=\"6\">&nbsp;</td>\n";
 echo "                </tr>\n";
 echo "              </table>\n";
 echo "            </td>\n";
 echo "          </tr>\n";
 echo "        </table>\n";
 echo "      </td>\n";
 echo "    </tr>\n";
 echo "  </table>\n";
Example #6
0
 echo "                <tr>\n";
 echo "                  <td align=\"center\">\n";
 echo "                    <table class=\"posthead\" width=\"95%\">\n";
 if ($available_styles = styles_get_available()) {
     echo "                      <tr>\n";
     echo "                        <td align=\"left\" class=\"posthead\">", gettext("Style"), ":</td>\n";
     echo "                        <td align=\"left\">", form_dropdown_array("style", htmlentities_array($available_styles), isset($new_user_prefs['STYLE']) && style_exists($new_user_prefs['STYLE']) ? htmlentities_array($new_user_prefs['STYLE']) : htmlentities_array(forum_get_setting('default_style', null, 'default')), "", "register_dropdown"), "</td>\n";
     echo "                      </tr>\n";
 }
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" class=\"posthead\">", gettext("Forum emoticons"), " [<a href=\"display_emoticons.php?webtag={$webtag}\" target=\"_blank\" class=\"popup 500x400\">", gettext("Preview"), "</a>]:</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array("emoticons", htmlentities_array($available_emoticons), isset($new_user_prefs['EMOTICONS']) && in_array($new_user_prefs['EMOTICONS'], array_keys($available_emoticons)) ? htmlentities_array($new_user_prefs['EMOTICONS']) : htmlentities_array(forum_get_setting('default_emoticons', null, 'default')), "", "register_dropdown"), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" class=\"posthead\" width=\"255\">", gettext("Preferred language"), ":</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array("language", htmlentities_array($available_langs), isset($new_user_prefs['LANGUAGE']) ? htmlentities_array($new_user_prefs['LANGUAGE']) : htmlentities_array(forum_get_setting('default_language', null, 'en')), "", "register_dropdown"), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" colspan=\"2\">&nbsp;</td>\n";
 echo "                      </tr>\n";
 echo "                    </table>\n";
 echo "                  </td>\n";
 echo "                </tr>\n";
 echo "              </table>\n";
 echo "            </td>\n";
 echo "          </tr>\n";
 echo "        </table>\n";
 echo "      </td>\n";
 echo "    </tr>\n";
 echo "  </table>\n";
 if (forum_get_setting('text_captcha_enabled', 'Y') && $text_captcha->generate_keys()) {
Example #7
0
 }
 echo "  <table cellpadding=\"0\" cellspacing=\"0\" width=\"600\">\n";
 echo "    <tr>\n";
 echo "      <td align=\"left\">\n";
 echo "        <table class=\"box\" width=\"100%\">\n";
 echo "          <tr>\n";
 echo "            <td align=\"left\" class=\"posthead\">\n";
 echo "              <table class=\"posthead\" width=\"100%\">\n";
 echo "                <tr>\n";
 echo "                  <td align=\"left\" class=\"subhead\" colspan=\"1\">", gettext("More Admin Options"), "</td>\n";
 echo "                </tr>\n";
 echo "                <tr>\n";
 echo "                  <td align=\"center\">\n";
 echo "                    <table width=\"90%\" class=\"posthead\">\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"center\">", form_dropdown_array('action', $admin_options_dropdown, false, false, 'admin_options_dropdown'), "&nbsp;", form_submit('action_submit', gettext("Go!")), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                      </tr>\n";
 echo "                    </table>\n";
 echo "                  </td>\n";
 echo "                </tr>\n";
 echo "              </table>\n";
 echo "            </td>\n";
 echo "          </tr>\n";
 echo "        </table>\n";
 echo "      </td>\n";
 echo "    </tr>\n";
 echo "  </table>\n";
 echo "  <br />\n";
Example #8
0
echo "                      </tr>\n";
if ($friends_array = pm_user_get_friends()) {
    if (isset($_GET['uid']) && is_numeric($_GET['uid'])) {
        $to_user = user_get($_GET['uid']);
        if (in_array($to_user['UID'], array_keys($friends_array))) {
            $t_to_uid = $to_user['UID'];
            $to_radio = 'friends';
        } else {
            $t_to_uid_others = $to_user['LOGON'];
        }
    }
    echo "                      <tr>\n";
    echo "                        <td align=\"left\">", form_radio("to_radio", "friends", gettext("Friends"), isset($to_radio) && $to_radio == "friends"), "</td>\n";
    echo "                      </tr>\n";
    echo "                      <tr>\n";
    echo "                        <td align=\"left\">", form_dropdown_array("t_to_uid", $friends_array, isset($t_to_uid) ? $t_to_uid : 0, "", "friends_dropdown"), "</td>\n";
    echo "                      </tr>\n";
    echo "                      <tr>\n";
    echo "                        <td align=\"left\">", form_radio("to_radio", "others", gettext("Others"), isset($to_radio) && $to_radio == "others" ? true : !isset($to_radio)), "</td>\n";
    echo "                      </tr>\n";
    echo "                      <tr>\n";
    echo "                        <td align=\"left\" style=\"white-space: nowrap\">", form_input_text_search("t_to_uid_others", isset($t_to_uid_others) ? htmlentities_array($t_to_uid_others) : "", false, false, SEARCH_LOGON, true, sprintf('title="%s"', gettext("Separate recipients by semi-colon or comma")), "post_to_others"), "</td>\n";
    echo "                      </tr>\n";
} else {
    if (isset($_GET['uid']) && is_numeric($_GET['uid'])) {
        $to_user = user_get($_GET['uid']);
        $t_to_uid_others = $to_user['LOGON'];
    }
    echo "                      <tr>\n";
    echo "                        <td align=\"left\" style=\"white-space: nowrap\">", form_input_text_search("t_to_uid_others", isset($t_to_uid_others) ? htmlentities_array($t_to_uid_others) : "", false, false, SEARCH_LOGON, true, sprintf('title="%s"', gettext("Separate recipients by semi-colon or comma")), "post_to_others"), "</td>\n";
    echo "                      </tr>\n";
Example #9
0
    echo "        ", form_input_hidden("page", htmlentities_array($page)), "\n";
    echo "        ", form_input_hidden('mark_read_confirm', 'N'), "\n";
    $labels = array(gettext("All Discussions"), gettext("Next 50 discussions"));
    $selected_option = THREAD_MARK_READ_ALL;
    if (sizeof($visible_threads_array) > 0) {
        $labels[] = gettext("Visible discussions");
        $selected_option = THREAD_MARK_READ_VISIBLE;
        $visible_threads = implode(',', array_filter($visible_threads_array, 'is_numeric'));
        echo "        ", form_input_hidden("mark_read_threads", htmlentities_array($visible_threads)), "\n";
    }
    if (isset($folder) && is_numeric($folder)) {
        echo "        ", form_input_hidden('folder', htmlentities_array($folder)), "\n";
        $labels[] = gettext("Selected folder");
        $selected_option = THREAD_MARK_READ_FOLDER;
    }
    echo "        ", form_dropdown_array("mark_read_type", $labels, $selected_option) . "\n";
    echo "        ", form_submit("mark_read_submit", gettext("Go!")) . "\n";
    echo "      </form>\n";
    echo "    </td>\n";
    echo "  </tr>\n";
    echo "</table>\n";
}
echo "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"2\">\n";
echo "  <tr>\n";
echo "    <td align=\"left\" class=\"smalltext\" colspan=\"2\">", gettext("Navigate"), ":</td>\n";
echo "  </tr>\n";
echo "  <tr>\n";
echo "    <td align=\"left\">&nbsp;</td>\n";
echo "    <td align=\"left\" class=\"smalltext\">\n";
echo "      <form accept-charset=\"utf-8\" name=\"f_nav\" method=\"get\" action=\"messages.php\" target=\"", html_get_frame_name('right'), "\">\n";
echo "        ", form_input_hidden('webtag', htmlentities_array($webtag)), "\n";
Example #10
0
 if (($groups_array = perm_get_user_group_names()) !== false) {
     echo "  <table cellpadding=\"0\" cellspacing=\"0\" width=\"800\">\n";
     echo "    <tr>\n";
     echo "      <td align=\"left\">\n";
     echo "        <table class=\"box\" width=\"100%\">\n";
     echo "          <tr>\n";
     echo "            <td align=\"left\" class=\"posthead\">\n";
     echo "              <table class=\"posthead\" width=\"100%\">\n";
     echo "                <tr>\n";
     echo "                  <td align=\"left\" class=\"subhead\" colspan=\"1\">", gettext("Add User to group"), "</td>\n";
     echo "                </tr>\n";
     echo "                <tr>\n";
     echo "                  <td align=\"center\">\n";
     echo "                    <table width=\"90%\" class=\"posthead\">\n";
     echo "                      <tr>\n";
     echo "                        <td align=\"center\">", gettext("Add user to group"), ":&nbsp;", form_dropdown_array('add_group', $groups_array, null, null, 'admin_options_dropdown'), "&nbsp;", form_submit('add_group_submit', gettext("Add")), "</td>\n";
     echo "                      </tr>\n";
     echo "                      <tr>\n";
     echo "                        <td align=\"left\">&nbsp;</td>\n";
     echo "                      </tr>\n";
     echo "                    </table>\n";
     echo "                  </td>\n";
     echo "                </tr>\n";
     echo "              </table>\n";
     echo "            </td>\n";
     echo "          </tr>\n";
     echo "        </table>\n";
     echo "      </td>\n";
     echo "    </tr>\n";
     echo "  </table>\n";
     echo "  <br />\n";
 echo "              <table class=\"posthead\" width=\"100%\">\n";
 echo "                <tr>\n";
 echo "                  <td align=\"left\" colspan=\"2\" class=\"subhead\">", gettext("Google AdSense"), "</td>\n";
 echo "                </tr>\n";
 echo "              </table>\n";
 echo "              <table class=\"posthead\" width=\"100%\">\n";
 echo "                <tr>\n";
 echo "                  <td align=\"center\">\n";
 echo "                    <table class=\"posthead\" width=\"95%\">\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"220\">", gettext("Display AdSense Ads for"), ":</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array('adsense_display_users', $adsense_user_type_array, isset($forum_global_settings['adsense_display_users']) && in_array($forum_global_settings['adsense_display_users'], array_keys($adsense_user_type_array)) ? $forum_global_settings['adsense_display_users'] : ADSENSE_DISPLAY_NONE), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" style=\"white-space: nowrap\">", gettext("Display AdSense Ads on"), ":</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array('adsense_display_pages', $adsense_page_type_array, isset($forum_global_settings['adsense_display_pages']) && in_array($forum_global_settings['adsense_display_pages'], array_keys($adsense_page_type_array)) ? $forum_global_settings['adsense_display_pages'] : ADSENSE_DISPLAY_TOP_OF_ALL_PAGES), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" colspan=\"2\">&nbsp;</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"center\" colspan=\"2\">\n";
 html_display_warning_msg(gettext("To change Google AdSense account details and other settings please see Global Forum Settings"), '95%', 'center');
 echo "                        </td>\n";
 echo "                      </tr>\n";
 echo "                    </table>\n";
 echo "                  </td>\n";
 echo "                </tr>\n";
 echo "              </table>\n";
 echo "            </td>\n";
 echo "          </tr>\n";
Example #12
0
 echo "                      </tr>\n";
 if ($forum_data['ACCESS_LEVEL'] == FORUM_RESTRICTED) {
     echo "                      <tr>\n";
     echo "                        <td align=\"left\" width=\"150\" class=\"posthead\">", gettext("Access level"), ":</td>\n";
     echo "                        <td align=\"left\" style=\"white-space: nowrap\">", form_dropdown_array("t_access", array(FORUM_DISABLED => gettext("Disabled"), FORUM_CLOSED => gettext("Closed"), FORUM_UNRESTRICTED => gettext("Open"), FORUM_RESTRICTED => gettext("Restricted"), FORUM_PASSWD_PROTECTED => gettext("Password Protected")), isset($_POST['t_access']) && is_numeric($_POST['t_access']) ? $forum_data['ACCESS_LEVEL'] : isset($forum_data['ACCESS_LEVEL']) && is_numeric($forum_data['ACCESS_LEVEL']) ? $forum_data['ACCESS_LEVEL'] : 0), "&nbsp;", form_submit("changepermissions[{$forum_data['WEBTAG']}]", gettext("Change")), "</td>\n";
     echo "                      </tr>\n";
 } else {
     if ($forum_data['ACCESS_LEVEL'] == FORUM_PASSWD_PROTECTED) {
         echo "                      <tr>\n";
         echo "                        <td align=\"left\" width=\"150\" class=\"posthead\">", gettext("Access level"), ":</td>\n";
         echo "                        <td align=\"left\" style=\"white-space: nowrap\">", form_dropdown_array("t_access", array(FORUM_DISABLED => gettext("Disabled"), FORUM_CLOSED => gettext("Closed"), FORUM_UNRESTRICTED => gettext("Open"), FORUM_RESTRICTED => gettext("Restricted"), FORUM_PASSWD_PROTECTED => gettext("Password Protected")), isset($_POST['t_access']) && is_numeric($_POST['t_access']) ? $forum_data['ACCESS_LEVEL'] : isset($forum_data['ACCESS_LEVEL']) && is_numeric($forum_data['ACCESS_LEVEL']) ? $forum_data['ACCESS_LEVEL'] : 0), "&nbsp;", form_submit("changepassword[{$forum_data['WEBTAG']}]", gettext("Change")), "</td>\n";
         echo "                      </tr>\n";
     } else {
         echo "                      <tr>\n";
         echo "                        <td align=\"left\" width=\"150\" class=\"posthead\">", gettext("Access level"), ":</td>\n";
         echo "                        <td align=\"left\" style=\"white-space: nowrap\">", form_dropdown_array("t_access", array(FORUM_DISABLED => gettext("Disabled"), FORUM_CLOSED => gettext("Closed"), FORUM_UNRESTRICTED => gettext("Open"), FORUM_RESTRICTED => gettext("Restricted"), FORUM_PASSWD_PROTECTED => gettext("Password Protected")), isset($_POST['t_access']) && is_numeric($_POST['t_access']) ? $forum_data['ACCESS_LEVEL'] : isset($forum_data['ACCESS_LEVEL']) && is_numeric($forum_data['ACCESS_LEVEL']) ? $forum_data['ACCESS_LEVEL'] : 0), "</td>\n";
         echo "                      </tr>\n";
     }
 }
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"150\" class=\"posthead\">", gettext("Default Forum"), ":</td>\n";
 echo "                        <td align=\"left\">", form_radio("t_default", 'Y', gettext("Yes"), isset($_POST['t_default']) && is_numeric($_POST['t_default']) && $_POST['t_default'] == 1 ? true : isset($forum_data['DEFAULT_FORUM']) && is_numeric($forum_data['DEFAULT_FORUM']) && $forum_data['DEFAULT_FORUM'] == 1 ? true : false), "&nbsp;", "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                        <td align=\"left\">", form_radio("t_default", 'N', gettext("No"), isset($_POST['t_default']) && is_numeric($_POST['t_default']) && $_POST['t_default'] == 0 ? true : isset($forum_data['DEFAULT_FORUM']) && is_numeric($forum_data['DEFAULT_FORUM']) && $forum_data['DEFAULT_FORUM'] == 0 ? true : false), "&nbsp;", "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                      </tr>\n";
Example #13
0
 echo "  <table cellpadding=\"0\" cellspacing=\"0\" width=\"700\">\n";
 echo "    <tr>\n";
 echo "      <td align=\"left\">\n";
 echo "        <table class=\"box\" width=\"100%\">\n";
 echo "          <tr>\n";
 echo "            <td align=\"left\" class=\"posthead\">\n";
 echo "              <table class=\"posthead\" width=\"100%\">\n";
 echo "                <tr>\n";
 echo "                  <td align=\"left\" class=\"subhead\" colspan=\"2\">", gettext("Edit Ban"), "</td>\n";
 echo "                </tr>\n";
 echo "                <tr>\n";
 echo "                  <td align=\"center\">\n";
 echo "                    <table class=\"posthead\" width=\"95%\">\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"150\" class=\"posthead\">", gettext("Ban Type"), ":</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array('bantype', $ban_types_list_array, $ban_data_array['BANTYPE']), form_input_hidden('old_bantype', htmlentities_array($ban_data_array['BANTYPE'])), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"150\" class=\"posthead\">", gettext("Ban Data"), ":</td>\n";
 echo "                        <td align=\"left\">", form_input_text('bandata', htmlentities_array($ban_data_array['BANDATA']), 52, 255), form_input_hidden('old_bandata', htmlentities_array($ban_data_array['BANDATA'])), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"150\" class=\"posthead\" valign=\"top\">", gettext("Comment"), ":</td>\n";
 echo "                        <td align=\"left\">", form_textarea('bancomment', htmlentities_array($ban_data_array['COMMENT']), 6, 50), form_input_hidden('old_bancomment', htmlentities_array($ban_data_array['COMMENT'])), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"150\" class=\"posthead\">", gettext("Ban Expires"), ":</td>\n";
 echo "                        <td align=\"left\">", form_date_dropdowns($ban_data_array['EXPIRESYEAR'], $ban_data_array['EXPIRESMONTH'], $ban_data_array['EXPIRESDAY'], "banexpires", 2002), form_input_hidden('old_banexpires', htmlentities_array($ban_data_array['EXPIRES'])), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
Example #14
0
    echo "                <tr>\n";
    echo "                  <td align=\"left\" style=\"white-space: nowrap\">", gettext("Forum style"), ":</td>\n";
    echo "                  <td align=\"left\">", form_dropdown_array("style", htmlentities_array($available_styles), isset($user_prefs['STYLE']) && style_exists($user_prefs['STYLE']) ? htmlentities_array($user_prefs['STYLE']) : htmlentities_array(forum_get_setting('default_style', null, 'default'))), "</td>\n";
    echo "                  <td align=\"right\" style=\"white-space: nowrap\">", $show_set_all ? form_checkbox("style_global", "Y", '', isset($user_prefs['STYLE_GLOBAL']) ? $user_prefs['STYLE_GLOBAL'] : false, sprintf('title="%s"', gettext("Set for all forums?"))) : form_input_hidden("style_global", 'Y'), "&nbsp;</td>\n";
    echo "                </tr>\n";
}
if (sizeof($available_emoticons) > 1) {
    echo "                <tr>\n";
    echo "                  <td align=\"left\" style=\"white-space: nowrap\">", gettext("Forum emoticons"), " [<a href=\"display_emoticons.php?webtag={$webtag}\" target=\"_blank\" class=\"emoticon_preview_popup\">", gettext("Preview"), "</a>]:</td>\n";
    echo "                  <td align=\"left\">", form_dropdown_array("emoticons", htmlentities_array($available_emoticons), isset($user_prefs['EMOTICONS']) && in_array($user_prefs['EMOTICONS'], array_keys($available_emoticons)) ? htmlentities_array($user_prefs['EMOTICONS']) : htmlentities_array(forum_get_setting('default_emoticons', null, 'default'))), "</td>\n";
    echo "                  <td align=\"right\" style=\"white-space: nowrap\">", $show_set_all ? form_checkbox("emoticons_global", "Y", '', isset($user_prefs['EMOTICONS_GLOBAL']) ? $user_prefs['EMOTICONS_GLOBAL'] : false, sprintf('title="%s"', gettext("Set for all forums?"))) : form_input_hidden("emoticons_global", 'Y'), "&nbsp;</td>\n";
    echo "                </tr>\n";
}
echo "                <tr>\n";
echo "                  <td align=\"left\" style=\"white-space: nowrap\">", gettext("Start page"), ":</td>\n";
echo "                  <td align=\"left\">", form_dropdown_array("start_page", array(START_PAGE_NORMAL => gettext("Start"), START_PAGE_MESSAGES => gettext("Messages"), START_PAGE_INBOX => gettext("Inbox"), START_PAGE_THREAD_LIST => gettext("Start page with thread list")), isset($user_prefs['START_PAGE']) ? $user_prefs['START_PAGE'] : 0), "</td>\n";
echo "                  <td align=\"right\" style=\"white-space: nowrap\">", $show_set_all ? form_checkbox("start_page_global", "Y", '', isset($user_prefs['START_PAGE_GLOBAL']) ? $user_prefs['START_PAGE_GLOBAL'] : false, sprintf('title="%s"', gettext("Set for all forums?"))) : form_input_hidden("start_page_global", 'Y'), "&nbsp;</td>\n";
echo "                </tr>\n";
echo "                <tr>\n";
echo "                  <td align=\"left\" colspan=\"2\">&nbsp;</td>\n";
echo "                </tr>\n";
echo "              </table>\n";
echo "            </td>\n";
echo "          </tr>\n";
echo "        </table>\n";
echo "      </td>\n";
echo "    </tr>\n";
echo "    <tr>\n";
echo "      <td align=\"left\">&nbsp;</td>\n";
echo "    </tr>\n";
echo "    <tr>\n";
Example #15
0
function form_date_dropdowns($year = 0, $month = 0, $day = 0, $prefix = false, $start_year = 0)
{
    // the end of 2037 is more or less the maximum time that
    // can be represented as a UNIX timestamp currently
    if (is_numeric($start_year) && $start_year > 0 && $start_year < 2037) {
        $years = array('&nbsp;') + range_keys($start_year, 2037);
    } else {
        $years = array('&nbsp;') + range_keys(date('Y', time()), 2037);
    }
    $days = array_merge(array('&nbsp;'), range(1, 31));
    $months = array_merge(array('&nbsp;'), lang_get_month_names());
    $output = form_dropdown_array("{$prefix}day", $days, $day) . "&nbsp;";
    $output .= form_dropdown_array("{$prefix}month", $months, $month) . "&nbsp;";
    $output .= form_dropdown_array("{$prefix}year", $years, $year) . "&nbsp;";
    return $output;
}
 echo "  <table cellpadding=\"0\" cellspacing=\"0\" width=\"700\">\n";
 echo "    <tr>\n";
 echo "      <td align=\"left\">\n";
 echo "        <table class=\"box\" width=\"100%\">\n";
 echo "          <tr>\n";
 echo "            <td align=\"left\" class=\"posthead\">\n";
 echo "              <table class=\"posthead\" width=\"100%\">\n";
 echo "                <tr>\n";
 echo "                  <td class=\"subhead\" align=\"left\" colspan=\"2\">", gettext("Edit item"), "</td>\n";
 echo "                </tr>\n";
 echo "                <tr>\n";
 echo "                  <td align=\"center\">\n";
 echo "                    <table class=\"posthead\" width=\"95%\">\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"150\">", gettext("Type"), ":</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array("t_type_new", $item_types_array, isset($_POST['t_type_new']) && is_numeric($_POST['t_type_new']) ? $_POST['t_type_new'] : $profile_item['TYPE']), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"150\">", gettext("Section Name"), ":</td>\n";
 echo "                        <td align=\"left\">", profile_section_dropdown($psid, "t_section_new"), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"150\">", gettext("Item Name"), ":</td>\n";
 echo "                        <td align=\"left\">", form_input_text("t_name_new", isset($_POST['t_name_new']) ? htmlentities_array($_POST['t_name_new']) : htmlentities_array($profile_item['NAME']), 52, 64), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"150\" valign=\"top\">", gettext("Options"), ":</td>\n";
 echo "                        <td align=\"left\">", form_textarea("t_options_new", isset($_POST['t_options_new']) ? htmlentities_array($_POST['t_options_new']) : htmlentities_array($profile_item['OPTIONS']), 6, 50), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" colspan=\"4\">&nbsp;</td>\n";
Example #17
0
function folder_draw_dropdown_all($default_fid, $field_name = "t_fid", $suffix = "", $custom_html = "", $class = "bhselect")
{
    if (!($db = db::get())) {
        return false;
    }
    if (!($table_prefix = get_table_prefix())) {
        return "";
    }
    $available_folders = array();
    $sql = "SELECT FID, TITLE, DESCRIPTION FROM `{$table_prefix}FOLDER` ";
    $sql .= "ORDER BY POSITION";
    if (!($result = $db->query($sql))) {
        return false;
    }
    if ($result->num_rows == 0) {
        return false;
    }
    while (($folder_data = $result->fetch_assoc()) !== null) {
        $available_folders[$folder_data['FID']] = htmlentities_array($folder_data['TITLE']);
    }
    if (sizeof($available_folders) == 0) {
        return false;
    }
    return form_dropdown_array($field_name . $suffix, $available_folders, $default_fid, $custom_html, $class);
}
Example #18
0
function poll_voting_form($poll_results, $poll_data)
{
    $poll_display = "<div align=\"center\">\n";
    $poll_display .= "  <table class=\"box\" cellpadding=\"0\" cellspacing=\"0\" width=\"580\">\n";
    $poll_display .= "    <tr>\n";
    $poll_display .= "      <td align=\"center\">\n";
    $poll_display .= "        <table width=\"560\">\n";
    foreach ($poll_results as $question_id => $poll_question) {
        $poll_display .= "          <tr>\n";
        $poll_display .= "            <td align=\"left\"><h2>" . word_filter_add_ob_tags($poll_question['QUESTION'], true) . "</h2></td>\n";
        $poll_display .= "          </tr>\n";
        $poll_display .= "          <tr>\n";
        $poll_display .= "            <td align=\"left\">\n";
        $poll_display .= "              <table width=\"100%\">\n";
        if ($poll_data['OPTIONTYPE'] == POLL_OPTIONS_DROPDOWN) {
            $dropdown_options_array = array_map('poll_dropdown_options_callback', $poll_question['OPTIONS_ARRAY']);
            $poll_display .= "                <tr>\n";
            $poll_display .= "                  <td align=\"left\" class=\"postbody\" valign=\"top\">" . form_dropdown_array("pollvote[{$question_id}]", $dropdown_options_array) . "</td>\n";
            $poll_display .= "                </tr>\n";
        } else {
            foreach ($poll_question['OPTIONS_ARRAY'] as $option_id => $option) {
                if (sizeof($poll_question['OPTIONS_ARRAY']) == 1 || $poll_question['ALLOW_MULTI'] == 'Y') {
                    $poll_display .= "                <tr>\n";
                    $poll_display .= "                  <td align=\"left\" class=\"postbody\" valign=\"top\" width=\"1%\">" . form_checkbox("pollvote[{$question_id}][{$option_id}]", 'Y', word_filter_add_ob_tags($option['OPTION_NAME']), false) . "</td>\n";
                    $poll_display .= "                </tr>\n";
                } else {
                    $poll_display .= "                <tr>\n";
                    $poll_display .= "                  <td align=\"left\" class=\"postbody\" valign=\"top\" width=\"1%\">" . form_radio("pollvote[{$question_id}]", $option_id, word_filter_add_ob_tags($option['OPTION_NAME']), false) . "</td>\n";
                    $poll_display .= "                </tr>\n";
                }
            }
        }
        $poll_display .= "              </table>\n";
        $poll_display .= "            </td>\n";
        $poll_display .= "          </tr>\n";
    }
    $poll_display .= "        </table>\n";
    $poll_display .= "      </td>\n";
    $poll_display .= "    </tr>\n";
    $poll_display .= "  </table>\n";
    $poll_display .= "</div>\n";
    return $poll_display;
}
Example #19
0
function thread_list_draw_top($mode, $folder = false)
{
    $webtag = get_webtag();
    forum_check_webtag_available($webtag);
    echo "<table width=\"100%\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">\n";
    echo "  <tr>\n";
    echo "    <td align=\"left\" class=\"postbody\">", html_style_image('post', gettext("New Discussion")), "&nbsp;<a href=\"post.php?webtag={$webtag}\" target=\"", html_get_frame_name('main'), "\">", gettext("New Discussion"), "</a></td>\n";
    echo "  </tr>\n";
    if (forum_get_setting('allow_polls', 'Y')) {
        echo "  <tr>\n";
        echo "    <td align=\"left\" class=\"postbody\">", html_style_image('poll', gettext("Create Poll")), "&nbsp;<a href=\"create_poll.php?webtag={$webtag}\" target=\"", html_get_frame_name('main'), "\">", gettext("Create Poll"), "</a></td>\n";
        echo "  </tr>\n";
    }
    echo "  <tr>\n";
    echo "    <td align=\"left\" class=\"postbody\">", html_style_image('search', gettext("Search")), "&nbsp;<a href=\"search.php?webtag={$webtag}\" target=\"", html_get_frame_name('right'), "\">", gettext("Search"), "</a></td>\n";
    echo "  </tr>\n";
    echo "  <tr>\n";
    echo "    <td align=\"left\" class=\"postbody\">", html_style_image('pm_unread', gettext("Inbox")), "&nbsp;<a href=\"pm.php?webtag={$webtag}\" target=\"", html_get_frame_name('main'), "\">", gettext("Inbox"), "</a> <span class=\"pmnewcount\" id=\"pm_message_count\"></span></td>\n";
    echo "  </tr>\n";
    echo "</table>\n";
    echo "<br />\n";
    $available_views = thread_list_available_views();
    echo "<form accept-charset=\"utf-8\" name=\"f_mode\" method=\"get\" action=\"thread_list.php\">\n";
    echo "  ", form_input_hidden("webtag", htmlentities_array($webtag)), "\n";
    echo "  <table width=\"100%\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">\n";
    echo "    <tr>\n";
    echo "      <td align=\"left\" class=\"postbody\">\n";
    echo "        ", form_dropdown_array("mode", $available_views, htmlentities_array($mode)), "&nbsp;", form_submit("go", gettext("Go!")), "\n";
    if (is_numeric($folder) && in_array($folder, folder_get_available_array())) {
        echo "        ", form_input_hidden("folder", htmlentities_array($folder)), "\n";
    }
    echo "      </td>\n";
    echo "    </tr>\n";
    echo "  </table>\n";
    echo "</form>\n";
}
Example #20
0
echo "                              </tr>\n";
echo "                              <tr>\n";
echo "                                <td align=\"right\">", form_submit("suggest", gettext("Suggest"), false, "dictionary_button"), "</td>\n";
echo "                              </tr>\n";
echo "                            </table>\n";
echo "                          </td>\n";
echo "                        </tr>\n";
echo "                        <tr>\n";
echo "                          <td align=\"left\" valign=\"top\" width=\"330\">\n";
echo "                            <table border=\"0\" width=\"100%\" cellpadding=\"0\" cellspacing=\"3\">\n";
echo "                              <tr>\n";
echo "                                <td align=\"left\" valign=\"top\" width=\"330\">\n";
if ($suggestions_array = $dictionary->get_suggestions_array()) {
    echo "                                  ", form_dropdown_array("suggestions", $suggestions_array, $dictionary->get_best_suggestion(), "size=\"5\"", "dictionary_best_selection"), "\n";
} else {
    echo "                                  ", form_dropdown_array("no_suggestions", array(gettext("(no suggestions)")), $dictionary->get_best_suggestion(), "size=\"5\"", "dictionary_best_selection"), "\n";
}
echo "                                </td>\n";
echo "                              </tr>\n";
echo "                            </table>\n";
echo "                          </td>\n";
echo "                        </tr>\n";
echo "                      </table>\n";
echo "                    </td>\n";
echo "                  </tr>\n";
echo "                  <tr>\n";
echo "                    <td align=\"left\">&nbsp;</td>\n";
echo "                  </tr>\n";
echo "                </table>\n";
echo "              </td>\n";
echo "            </tr>\n";
 echo "                    <table class=\"posthead\" width=\"95%\">\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"200\" class=\"posthead\">", gettext("Feed User Account"), ":</td>\n";
 echo "                        <td align=\"left\">", form_input_text_search("t_user", isset($_POST['t_user']) ? htmlentities_array($_POST['t_user']) : (isset($rss_feed['LOGON']) ? htmlentities_array($rss_feed['LOGON']) : ""), 26, 15), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"200\" class=\"posthead\">", gettext("Thread Title Prefix"), ":</td>\n";
 echo "                        <td align=\"left\">", form_input_text("t_prefix", isset($_POST['t_prefix']) ? htmlentities_array($_POST['t_prefix']) : (isset($rss_feed['PREFIX']) ? htmlentities_array($rss_feed['PREFIX']) : ""), 29, 16), form_input_hidden("t_prefix_old", isset($rss_feed['PREFIX']) ? htmlentities_array($rss_feed['PREFIX']) : ""), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"200\" class=\"posthead\">", gettext("Feed Folder Name"), ":</td>\n";
 echo "                        <td align=\"left\">", folder_draw_dropdown_all(isset($_POST['t_fid']) ? htmlentities_array($_POST['t_fid']) : (isset($rss_feed['FID']) ? $rss_feed['FID'] : 0), "t_fid", "", "", "post_folder_dropdown"), form_input_hidden("t_fid_old", isset($rss_feed['FID']) ? htmlentities_array($rss_feed['FID']) : ""), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"200\" class=\"posthead\">", gettext("Update Frequency"), ":</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array("t_frequency", $update_frequencies_array, isset($_POST['t_frequency']) ? htmlentities_array($_POST['t_frequency']) : (isset($rss_feed['FREQUENCY']) ? $rss_feed['FREQUENCY'] : 1440), "", "post_folder_dropdown"), form_input_hidden("t_frequency_old", isset($rss_feed['FREQUENCY']) ? htmlentities_array($rss_feed['FREQUENCY']) : ""), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"200\" class=\"posthead\">", gettext("Max Item Count"), ":</td>\n";
 echo "                        <td align=\"left\">", form_input_text("t_max_item_count", isset($_POST['t_max_item_count']) ? htmlentities_array($_POST['t_max_item_count']) : (isset($rss_feed['MAX_ITEM_COUNT']) ? $rss_feed['MAX_ITEM_COUNT'] : 10), 6, 4), form_input_hidden("t_max_item_count_old", isset($rss_feed['MAX_ITEM_COUNT']) ? htmlentities_array($rss_feed['MAX_ITEM_COUNT']) : 10), "&nbsp;<span class=\"smalltext\">", gettext("Min: 1, Max: 10"), "</span></td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                      </tr>\n";
 echo "                    </table>\n";
 echo "                  </td>\n";
 echo "                </tr>\n";
 echo "              </table>\n";
 echo "            </td>\n";
 echo "          </tr>\n";
Example #22
0
         profile_item_add_clear_entry($profile_item_options_array, $profile_item['TYPE']);
         if ($profile_item['TYPE'] == PROFILE_ITEM_RADIO) {
             echo form_radio_array("t_entry[{$profile_item['PIID']}]", $profile_item_options_array, isset($t_entry_array[$profile_item['PIID']]) ? htmlentities_array($t_entry_array[$profile_item['PIID']]) : htmlentities_array($profile_item['ENTRY'])), "\n";
         } else {
             echo form_dropdown_array("t_entry[{$profile_item['PIID']}]", $profile_item_options_array, isset($t_entry_array[$profile_item['PIID']]) ? htmlentities_array($t_entry_array[$profile_item['PIID']]) : htmlentities_array($profile_item['ENTRY']), null, 'bhinputprofileitem'), "\n";
         }
     } else {
         if ($profile_item['TYPE'] == PROFILE_ITEM_MULTI_TEXT) {
             echo form_textarea("t_entry[{$profile_item['PIID']}]", isset($t_entry_array[$profile_item['PIID']]) ? htmlentities_array($t_entry_array[$profile_item['PIID']]) : htmlentities_array($profile_item['ENTRY']), null, null, null, 'bhinputprofileitem'), "\n";
         } else {
             echo form_input_text("t_entry[{$profile_item['PIID']}]", isset($t_entry_array[$profile_item['PIID']]) ? htmlentities_array($t_entry_array[$profile_item['PIID']]) : htmlentities_array($profile_item['ENTRY']), null, null, null, 'bhinputprofileitem'), "\n";
         }
     }
     echo "</td>\n";
     if ($admin_edit === false) {
         echo "                        <td>", form_dropdown_array("t_entry_private[{$profile_item['PIID']}]", array(gettext("Public"), gettext("Friends"), gettext("Only Me")), $profile_item['PRIVACY'], null, 'bhinputprofileprivacy'), "</td>\n";
     } else {
         echo "                        <td>&nbsp;</td>\n";
     }
     echo "                      </tr>\n";
 }
 echo "                      <tr>\n";
 echo "                        <td>&nbsp;</td>\n";
 echo "                      </tr>\n";
 echo "                    </table>\n";
 echo "                  </td>\n";
 echo "                </tr>\n";
 echo "              </table>\n";
 echo "            </td>\n";
 echo "          </tr>\n";
 echo "          <tr>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"200\">", gettext("Matched Text"), ":</td>\n";
 echo "                        <td align=\"left\">", form_input_text("match_text", htmlentities_array($word_filter_array['MATCH_TEXT']), 40), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" width=\"200\">", gettext("Replacement Text"), ":</td>\n";
 echo "                        <td align=\"left\">", form_input_text("replace_text", htmlentities_array($word_filter_array['REPLACE_TEXT']), 40), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" valign=\"top\" width=\"200\">", gettext("Filter Type"), ":</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array("filter_option", array(gettext("All"), gettext("Whole Word"), gettext("PREG")), $word_filter_array['FILTER_TYPE']), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" valign=\"top\" width=\"200\">", gettext("Filter Enabled"), ":</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array("filter_enabled", array(WORD_FILTER_ENABLED => gettext("Yes"), WORD_FILTER_DISABLED => gettext("No")), $word_filter_array['FILTER_ENABLED']), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                      </tr>\n";
 echo "                    </table>\n";
 echo "                  </td>\n";
 echo "                </tr>\n";
 echo "              </table>\n";
 echo "            </td>\n";
 echo "          </tr>\n";
 echo "        </table>\n";
 echo "      </td>\n";
 echo "    </tr>\n";
 echo "    <tr>\n";
 echo "      <td align=\"left\">&nbsp;</td>\n";
Example #24
0
function profile_section_dropdown($default_psid, $field_name = 't_psid')
{
    if (!($db = db::get())) {
        return '';
    }
    if (!($table_prefix = get_table_prefix())) {
        return '';
    }
    $sql = "SELECT PSID, NAME FROM `{$table_prefix}PROFILE_SECTION`";
    if (!($result = $db->query($sql))) {
        return '';
    }
    if ($result->num_rows == 0) {
        return '';
    }
    while ($profile_section_data = $result->fetch_assoc()) {
        $profile_sections_array[$profile_section_data['PSID']] = htmlentities_array($profile_section_data['NAME']);
    }
    return form_dropdown_array($field_name, $profile_sections_array, $default_psid);
}
Example #25
0
         echo "                        <td align=\"left\" class=\"subhead\" colspan=\"3\">{$profile_item['SECTION_NAME']}</td>\n";
         echo "                        <td align=\"left\" class=\"subhead\" width=\"1%\">&nbsp;</td>\n";
         echo "                      </tr>\n";
     }
 }
 $last_psid = $profile_item['PSID'];
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                        <td align=\"left\" width=\"225\">{$profile_item['ITEM_NAME']}</td>\n";
 if ($profile_item['TYPE'] == PROFILE_ITEM_RADIO || $profile_item['TYPE'] == PROFILE_ITEM_DROPDOWN) {
     $profile_item_options_array = htmlentities_array(explode("\n", $profile_item['OPTIONS']));
     profile_item_add_clear_entry($profile_item_options_array, $profile_item['TYPE']);
     if ($profile_item['TYPE'] == PROFILE_ITEM_RADIO) {
         echo "                        <td align=\"left\" valign=\"top\">", form_radio_array("t_entry[{$profile_item['PIID']}]", $profile_item_options_array, isset($t_entry_array[$profile_item['PIID']]) ? htmlentities_array($t_entry_array[$profile_item['PIID']]) : htmlentities_array($profile_item['ENTRY'])), "</td>\n";
     } else {
         echo "                        <td align=\"left\" valign=\"top\">", form_dropdown_array("t_entry[{$profile_item['PIID']}]", $profile_item_options_array, isset($t_entry_array[$profile_item['PIID']]) ? htmlentities_array($t_entry_array[$profile_item['PIID']]) : htmlentities_array($profile_item['ENTRY']), false, 'bhinputprofileitem'), "</td>\n";
     }
     if ($admin_edit === false) {
         echo "                        <td align=\"right\" valign=\"top\">", form_checkbox("t_entry_private[{$profile_item['PIID']}]", "Y", '', isset($profile_item['PRIVACY']) && $profile_item['PRIVACY'] == PROFILE_ITEM_PRIVATE, sprintf("title=%s", gettext("Friends only?"))), "</td>\n";
     } else {
         echo "                        <td align=\"left\" valign=\"top\">&nbsp;</td>\n";
     }
 } else {
     if ($profile_item['TYPE'] == PROFILE_ITEM_MULTI_TEXT) {
         echo "                        <td align=\"left\" valign=\"top\">", form_textarea("t_entry[{$profile_item['PIID']}]", isset($t_entry_array[$profile_item['PIID']]) ? htmlentities_array($t_entry_array[$profile_item['PIID']]) : htmlentities_array($profile_item['ENTRY']), false, false, false, 'bhinputprofileitem'), "</td>\n";
         if ($admin_edit === false) {
             echo "                        <td align=\"right\" valign=\"top\">", form_checkbox("t_entry_private[{$profile_item['PIID']}]", "Y", '', isset($profile_item['PRIVACY']) && $profile_item['PRIVACY'] == PROFILE_ITEM_PRIVATE, sprintf("title=%s", gettext("Friends only?"))), "</td>\n";
         } else {
             echo "                        <td align=\"left\" valign=\"top\">&nbsp;</td>\n";
         }
         echo "                      </tr>\n";
Example #26
0
echo "           </tr>\n";
echo "         </table>\n";
echo "      </td>\n";
echo "    </tr>\n";
echo "    <tr>\n";
echo "      <td align=\"left\">&nbsp;</td>\n";
echo "    </tr>\n";
echo "    <tr>\n";
echo "      <td align=\"left\">\n";
echo "        <table cellpadding=\"0\" cellspacing=\"0\" width=\"100%\">\n";
echo "          <tr>\n";
echo "            <td align=\"left\" width=\"40%\">&nbsp;</td>\n";
echo "            <td align=\"center\" style=\"white-space: nowrap\" width=\"20%\">";
html_page_links("visitor_log.php?webtag={$webtag}&page={$page}&profile_selection={$profile_items_selected_encoded_string}&user_search={$user_search}&sort_by={$sort_by}&sort_dir={$sort_dir}&hide_empty={$hide_empty}&hide_guests={$hide_guests}", $page, $user_profile_array['user_count'], 10);
echo "            </td>\n";
echo "            <td align=\"right\" style=\"white-space: nowrap\" width=\"40%\">", form_dropdown_array('add_column', $profile_dropdown_array), "&nbsp;", form_submit('add', gettext("Add")), "</td>\n";
echo "          </tr>\n";
echo "        </table>\n";
echo "      </td>\n";
echo "    </tr>\n";
echo "    <tr>\n";
echo "      <td align=\"left\">&nbsp;</td>\n";
echo "    </tr>\n";
echo "  </table>\n";
echo "</form>\n";
echo "<form accept-charset=\"utf-8\" name=\"f_options\" action=\"visitor_log.php\" method=\"post\">\n";
echo "  ", form_csrf_token_field(), "\n";
echo "  ", form_input_hidden('webtag', htmlentities_array($webtag)), "\n";
echo "  ", form_input_hidden('page', htmlentities_array($page)), "\n";
echo "  ", form_input_hidden('sort_by', htmlentities_array($sort_by)), "\n";
echo "  ", form_input_hidden('sort_dir', htmlentities_array($sort_dir)), "\n";
Example #27
0
function links_folder_dropdown($default_fid, $folders)
{
    $default_value = 0;
    $labels = array();
    foreach (array_keys($folders) as $key) {
        $labels[$key] = links_get_folder_path_links($key, $folders, false);
        if ($key == $default_fid) {
            $default_value = $key;
        }
    }
    return form_dropdown_array("fid", $labels, $default_value, null, "links_dropdown");
}
Example #28
0
echo "          <tr>\n";
echo "            <td align=\"left\" class=\"posthead\">\n";
echo "              <table class=\"posthead\" width=\"100%\">\n";
echo "                <tr>\n";
echo "                  <td align=\"left\" colspan=\"3\" class=\"subhead\">", gettext("Private Message Export Options"), "</td>\n";
echo "                </tr>\n";
echo "                <tr>\n";
echo "                  <td align=\"left\" rowspan=\"7\" width=\"1%\">&nbsp;</td>\n";
echo "                </tr>\n";
echo "                <tr>\n";
echo "                  <td align=\"left\" width=\"250\" style=\"white-space: nowrap\">", gettext("Export as type"), ":</td>\n";
echo "                  <td align=\"left\">", form_dropdown_array("pm_export_type", array(gettext("HTML"), gettext("XML"), gettext("CSV")), isset($user_prefs['PM_EXPORT_TYPE']) && is_numeric($user_prefs['PM_EXPORT_TYPE']) ? $user_prefs['PM_EXPORT_TYPE'] : 0), "</td>\n";
echo "                </tr>\n";
echo "                <tr>\n";
echo "                  <td align=\"left\" width=\"250\" style=\"white-space: nowrap\">", gettext("Export messages as"), ":</td>\n";
echo "                  <td align=\"left\">", form_dropdown_array("pm_export_file", array(gettext("One file for all messages"), gettext("One file per message")), isset($user_prefs['PM_EXPORT_FILE']) && is_numeric($user_prefs['PM_EXPORT_FILE']) ? $user_prefs['PM_EXPORT_FILE'] : 0), "</td>\n";
echo "                </tr>\n";
echo "                <tr>\n";
echo "                  <td align=\"left\" colspan=\"2\" style=\"white-space: nowrap\">", form_checkbox("pm_export_attachments", "Y", gettext("Export attachments"), isset($user_prefs['PM_EXPORT_ATTACHMENTS']) && $user_prefs['PM_EXPORT_ATTACHMENTS'] == "Y" ? true : false), "</td>\n";
echo "                </tr>\n";
echo "                <tr>\n";
echo "                  <td align=\"left\" colspan=\"2\" style=\"white-space: nowrap\">", form_checkbox("pm_export_style", "Y", gettext("Include forum style sheet"), isset($user_prefs['PM_EXPORT_STYLE']) && $user_prefs['PM_EXPORT_STYLE'] == "Y" ? true : false), "</td>\n";
echo "                </tr>\n";
echo "                <tr>\n";
echo "                  <td align=\"left\" colspan=\"2\" style=\"white-space: nowrap\">", form_checkbox("pm_export_wordfilter", "Y", gettext("Apply word filter to messages"), isset($user_prefs['PM_EXPORT_WORDFILTER']) && $user_prefs['PM_EXPORT_WORDFILTER'] == "Y" ? true : false), "</td>\n";
echo "                </tr>\n";
echo "                <tr>\n";
echo "                  <td align=\"left\" colspan=\"2\">&nbsp;</td>\n";
echo "                </tr>\n";
echo "              </table>\n";
echo "            </td>\n";
echo "                </tr>\n";
echo "              </table>\n";
echo "            </td>\n";
echo "          </tr>\n";
echo "        </table>\n";
echo "      </td>\n";
echo "    </tr>\n";
echo "    <tr>\n";
echo "      <td align=\"left\">&nbsp;</td>\n";
echo "    </tr>\n";
echo "    <tr>\n";
echo "      <td align=\"left\" width=\"33%\">&nbsp;</td>\n";
echo "      <td class=\"postbody\" align=\"center\">";
html_page_links("folder_subscriptions.php?webtag={$webtag}&search_keyword={$search_keyword}&view={$view}", $page, $folder_subscriptions['folder_count'], 20, "main_page");
echo "      </td>\n";
echo "      <td align=\"right\" width=\"33%\">", gettext("View"), ":&nbsp;", form_dropdown_array('view', array(FOLDER_IGNORED => gettext("Ignored"), FOLDER_SUBSCRIBED => gettext("Subscribed")), $view), "&nbsp;", form_submit("view_submit", gettext("Go!")), "</td>\n";
echo "    </tr>\n";
if (sizeof($folder_subscriptions['folder_array']) > 0) {
    echo "    <tr>\n";
    echo "      <td align=\"left\">&nbsp;</td>\n";
    echo "    </tr>\n";
    echo "    <tr>\n";
    echo "      <td align=\"center\" colspan=\"3\">", form_submit("save", gettext("Reset Selected")), "</td>\n";
    echo "    </tr>\n";
}
echo "  </table>\n";
echo "</form>\n";
echo "<br />\n";
echo "<form accept-charset=\"utf-8\" method=\"post\" action=\"folder_subscriptions.php\" target=\"_self\">\n";
echo "  ", form_csrf_token_field(), "\n";
echo "  ", form_input_hidden('webtag', htmlentities_array($webtag)), "\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">", gettext("Matched Text"), ":</td>\n";
 echo "                        <td align=\"left\">", form_input_text("match_text", isset($_POST['match_text']) ? htmlentities_array($_POST['match_text']) : htmlentities_array($word_filter_array['MATCH_TEXT']), 60), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">", gettext("Replacement Text"), ":</td>\n";
 echo "                        <td align=\"left\">", form_input_text("replace_text", isset($_POST['replace_text']) ? htmlentities_array($_POST['replace_text']) : htmlentities_array($word_filter_array['REPLACE_TEXT']), 60), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" valign=\"top\">", gettext("Filter Type"), ":</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array("filter_option", array(gettext("All"), gettext("Whole Word"), gettext("PREG")), isset($_POST['filter_option']) ? htmlentities_array($_POST['filter_option']) : htmlentities_array($word_filter_array['FILTER_TYPE'])), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\" valign=\"top\">", gettext("Filter Enabled"), ":</td>\n";
 echo "                        <td align=\"left\">", form_dropdown_array("filter_enabled", array(WORD_FILTER_ENABLED => gettext("Yes"), WORD_FILTER_DISABLED => gettext("No")), isset($_POST['filter_enabled']) ? htmlentities_array($_POST['filter_enabled']) : htmlentities_array($word_filter_array['FILTER_ENABLED'])), "</td>\n";
 echo "                      </tr>\n";
 echo "                      <tr>\n";
 echo "                        <td align=\"left\">&nbsp;</td>\n";
 echo "                      </tr>\n";
 echo "                    </table>\n";
 echo "                  </td>\n";
 echo "                </tr>\n";
 echo "              </table>\n";
 echo "            </td>\n";
 echo "          </tr>\n";
 echo "        </table>\n";
 echo "      </td>\n";
 echo "    </tr>\n";
 echo "    <tr>\n";
 echo "      <td align=\"left\">&nbsp;</td>\n";