예제 #1
0
$spell_check_button = $FUD_OPT_1 & 2097152 && extension_loaded('pspell') && $usr->pspell_lang ? '<input type="submit" class="button" value="Spell-check Message" name="spell">&nbsp;' : '';
if (isset($_POST['preview']) || isset($_POST['spell'])) {
    $text = apply_custom_replace($_POST['msg_body']);
    $text_s = apply_custom_replace($_POST['msg_subject']);
    if ($FUD_OPT_1 & 4096) {
        $text = tags_to_html($text, $FUD_OPT_1 & 16384);
    } else {
        if ($FUD_OPT_1 & 2048) {
            $text = nl2br(htmlspecialchars($text));
        }
    }
    if ($FUD_OPT_1 & 6144) {
        char_fix($text);
    }
    if ($FUD_OPT_1 & 8192 && !$msg_smiley_disabled) {
        $text = smiley_to_post($text);
    }
    $text_s = htmlspecialchars($text_s);
    char_fix($text_s);
    $spell = $spell_check_button && isset($_POST['spell']);
    if ($spell && strlen($text)) {
        $text = check_data_spell($text, 'body', $usr->pspell_lang);
    }
    fud_wordwrap($text);
    $subj = $spell && !$no_spell_subject && $text_s ? check_data_spell($text_s, 'subject', $usr->pspell_lang) : $text_s;
    $signature = $FUD_OPT_1 & 32768 && $usr->sig && $msg_show_sig ? '<p><u>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</u><br />' . $usr->sig . '' : '';
    $apply_spell_changes = $spell ? '<input type="submit" class="button" name="btn_spell" value="Apply Spelling Changes">&nbsp;' : '';
    $preview_message = '<div align="center"><table border="0" cellspacing="1" cellpadding="2" class="PreviewTable">
<tr><th colspan=2>Post Preview</th></tr>
<tr><td class="RowStyleA"><font class="MsgSubText">' . $subj . '</font></td></tr>
<tr><td class="RowStyleA"><font class="MsgBodyText">' . $text . $signature . '</font></td></tr>
예제 #2
0
     }
 }
 $uent->bday = fmt_year($_POST['b_year']) . str_pad((int) $_POST['b_month'], 2, '0', STR_PAD_LEFT) . str_pad((int) $_POST['b_day'], 2, '0', STR_PAD_LEFT);
 $uent->sig = apply_custom_replace($uent->sig);
 if ($FUD_OPT_1 & 131072) {
     $uent->sig = tags_to_html($uent->sig, $FUD_OPT_1 & 524288);
 } else {
     if ($FUD_OPT_1 & 65536) {
         $uent->sig = nl2br(htmlspecialchars($uent->sig));
     }
 }
 if ($FUD_OPT_1 & 196608) {
     char_fix($uent->sig);
 }
 if ($FUD_OPT_1 & 262144) {
     $uent->sig = smiley_to_post($uent->sig);
 }
 fud_wordwrap($uent->sig);
 if ($uent->bio) {
     $uent->bio = htmlspecialchars($uent->bio);
     char_fix($uent->bio);
 }
 if (!$uent->icq && !($uent->users_opt & 4)) {
     $uent->users_opt |= 4;
 }
 /* Restore avatar values to their previous values */
 $uent->avatar = $old_avatar;
 $uent->avatar_loc = $old_avatar_loc;
 $old_opt = $uent->users_opt & (4194304 | 16777216 | 8388608);
 $uent->users_opt |= 4194304 | 16777216 | 8388608;
 /* prevent non-confirmed users from playing with avatars, yes we are that cruel */
예제 #3
0
/* remove a poll option */
if (isset($_GET['del_id'])) {
    poll_del_opt((int) $_GET['del_id'], $pl_id);
}
/* Adding or Updating poll options */
if (!empty($_POST['pl_upd']) || !empty($_POST['pl_add'])) {
    $pl_option = apply_custom_replace($_POST['pl_option']);
    if ($frm->forum_opt & 16) {
        $pl_option = tags_to_html($pl_option, $frm->group_cache_opt & 32768);
    } else {
        if ($frm->forum_opt & 8) {
            $pl_option = nl2br(htmlspecialchars($pl_option));
        }
    }
    if ($frm->group_cache_opt & 16384 && !isset($_POST['pl_smiley_disabled'])) {
        $pl_option = smiley_to_post($pl_option);
    }
    if (isset($_POST['pl_upd'], $_POST['pl_option_id'])) {
        poll_opt_sync((int) $_POST['pl_option_id'], $pl_option);
    } else {
        poll_opt_add($pl_option, $pl_id);
    }
    $pl_option = '';
}
/* if we have a poll, fetch poll options */
if ($pl_id) {
    $poll_opts = poll_fetch_opts($pl_id);
}
/* edit a poll option */
if (isset($_GET['pl_optedit'])) {
    $pl_option = @$poll_opts[$_GET['pl_optedit']];