Example #1
0
} else {
    if ($db_cloudgdcode && defined('AJAX') && S::inArray($action, array('reply', 'quote'))) {
        $keepCloudCaptchaCode = true;
    }
    PostCheck(1, $db_gdcheck & 4 && (!$db_postgd || $winddb['postnum'] < $db_postgd), $db_ckquestion & 4 && (!$postq || $winddb['postnum'] < $postq) && $db_question);
    !$windid && ($windid = '游客');
    /*
    if ($db_xforwardip && $_POST['_hexie'] != GetVerify($onlineip.$winddb['regdate'].$fid.$tid)) {
    	Showmsg('undefined_action');
    }
    */
}
//默认动漫表情处理
if ($db_windmagic && ($action == 'new' || $action == 'modify' && $pid == 'tpc')) {
    $mDef = '';
    //* @include_once pwCache::getPath(D_P."data/bbscache/myshow_default.php");
    pwCache::getData(D_P . "data/bbscache/myshow_default.php");
}
//校验token
if ($pwServer['REQUEST_METHOD'] == 'POST') {
    PostCheck(1, 0, 0, 1);
}
if ($action == "new") {
    require_once R_P . 'require/postnew.php';
} elseif ($action == "reply" || $action == "quote") {
    require_once R_P . 'require/postreply.php';
} elseif ($action == "modify") {
    require_once R_P . 'require/postmodify.php';
} else {
    Showmsg('undefined_action');
}
Example #2
0
$file = 'lastupdate.txt';
//flickrのid
$f_id = "";
// OAuthオブジェクト生成
$to = new TwitterOAuth($consumer_key, $consumer_secret, $access_token, $access_token_secret);
$url = 'http://api.flickr.com/services/feeds/photos_public.gne?id=' . $f_id . '&lang=en-us&format=rss_200';
// 投稿するRSS
$rss = file_get_contents($url);
$oXML = simplexml_load_string($rss);
$oItems = $oXML->channel->item;
$i = 0;
foreach ($oItems as $Item) {
    if ($i >= CHECK_RSS_COUNT) {
        break 1;
    }
    if (!PostCheck($Item->link, $file)) {
        $sLink = Shorten($Item->link);
        $text = $Item->title . " " . $sLink;
        // ツイート文言
        $res = $to->OAuthRequest("http://api.twitter.com/1/statuses/update.xml", "POST", array("status" => $text));
        // 成功したらfileに書き込む
        file_put_contents($file, (string) $Item->link);
    }
    $i++;
}
// twitterAPIの返りオブジェクト,RSSオブジェクトのタイトル
function PostCheck($sHead, $file)
{
    $sHead = (string) $sHead;
    // fileから最後に投稿したlinkとマッチするかチェック
    if (mb_strpos(file_get_contents($file), $sHead) !== false) {
Example #3
0
function deleteThreadsHander($tidarray)
{
    global $windid, $manager, $groupid;
    PostCheck();
    (!CkInArray($windid, $manager) || $groupid != 3) && Showmsg('mawhole_right');
    if ($tidarray == "") {
        Showmsg('data_error');
    }
    $tidarray = explode("|", $tidarray);
    if (!is_array($tidarray)) {
        Showmsg('data_error');
    }
    $forums = array();
    foreach ($tidarray as $v) {
        if ($v == "") {
            continue;
        }
        list($fid, $tid) = explode("_", $v);
        if (intval($fid) < 0 && intval($tid) < 0) {
            continue;
        }
        $forums[$fid][] = $tid;
    }
    $threadManager = L::loadclass('threadmanager');
    foreach ($forums as $fid => $threadIds) {
        $threadManager->deleteByThreadIds($fid, $threadIds);
    }
    echo getLangInfo('other', 'search_manager_success');
    ajax_footer();
}
Example #4
0
function deleteThreadsHander($tidarray)
{
    global $windid, $manager, $groupid, $SYSTEM;
    PostCheck();
    (!$SYSTEM['superright'] || !$SYSTEM['delatc']) && Showmsg('mawhole_right');
    if ($tidarray == "") {
        Showmsg('data_error');
    }
    $tidarray = explode("|", $tidarray);
    if (!is_array($tidarray)) {
        Showmsg('data_error');
    }
    $forums = $threadIds = array();
    foreach ($tidarray as $v) {
        if ($v == "") {
            continue;
        }
        if (intval($v) < 0) {
            continue;
        }
        $threadIds[] = $v;
    }
    /**
    	$threadManager = L::loadclass('threadmanager', 'forum');
    	foreach($forums as $fid=>$threadIds){
    		$threadManager->deleteByThreadIds($fid,$threadIds);
    	}**/
    $threadService = L::loadclass('threads', 'forum');
    foreach ($forums as $fid => $_threadIds) {
        $threadService->deleteByThreadIds($_threadIds);
        Perf::gatherInfo('changeThreadWithForumIds', array('fid' => $fid));
    }
    $delarticle = L::loadClass('DelArticle', 'forum');
    $delarticle->delTopicByTids($threadIds, true);
    echo getLangInfo('other', 'search_manager_success');
    ajax_footer();
}
Example #5
0
<?php

!defined('P_W') && exit('Forbidden');
define('AJAX', '1');
require_once R_P . 'require/functions.php';
!$winduid && Showmsg('not_login');
S::gp(array('action'));
if ($action == 'delatt') {
    PostCheck();
    S::gp(array('did', 'aid'));
    empty($aid) && Showmsg('job_attach_error');
    $attach = $db->get_one("SELECT * FROM pw_attachs WHERE aid=" . S::sqlEscape($aid));
    !$attach && Showmsg('job_attach_error');
    if (empty($attach['attachurl']) || strpos($attach['attachurl'], '..') !== false) {
        Showmsg('job_attach_error');
    }
    $aid = $attach['aid'];
    //获取管理权限
    $isGM = S::inArray($windid, $manager);
    !$isGM && ($groupid = 3 && ($isGM = 1));
    if ($isGM) {
        $admincheck = 1;
    } else {
        $admincheck = 0;
    }
    $attach['attachurl'] = "diary/" . $attach['attachurl'];
    if ($admincheck || $attach['uid'] == $winduid) {
        pwDelatt($attach['attachurl'], $db_ifftp);
        pwFtpClose($ftp);
        $diaryService = L::loadClass('Diary', 'diary');
        /* @var $diaryService PW_Diary */
Example #6
0
    if (is_array($db_enhideset['type'])) {
        foreach ($db_enhideset['type'] as $key => $value) {
            $enhidetype .= "<option value=\"{$value}\">" . $credit->cType[$value] . "</option>";
        }
    }
    require_once R_P . 'require/showimg.php';
    list($postFaceUrl) = showfacedesign($winddb['icon'], 1, 's');
    /**
     * 标题表情
     */
    $icondb = array('1' => '1.gif', '2' => '2.gif', '3' => '3.gif', '4' => '4.gif', '5' => '5.gif', '6' => '6.gif', '7' => '7.gif', '8' => '8.gif');
    if ($db_allowupload && $_G['allowupload']) {
        $mutiupload = $db->get_value("SELECT COUNT(*) AS sum FROM pw_attachs WHERE tid=0 AND pid='0' AND uid=" . pwEscape($winduid));
    }
} else {
    PostCheck(1, $db_gdcheck & 4 && $winddb['postnum'] < $db_postgd, $winddb['postnum'] < $postq);
    !$windid && ($windid = '游客');
    /*
    if ($db_xforwardip && $_POST['_hexie'] != GetVerify($onlineip.$winddb['regdate'].$fid.$tid)) {
    	Showmsg('undefined_action');
    }
    */
}
//默认动漫表情处理
if ($db_windmagic && ($action == 'new' || $action == 'modify' && $pid == 'tpc')) {
    $mDef = '';
    @(include_once D_P . "data/bbscache/myshow_default.php");
}
if ($action == "new") {
    require_once R_P . 'require/postnew.php';
} elseif ($action == "reply" || $action == "quote") {
Example #7
0
         foreach ($o_classdb as $key => $value) {
             $o_cate[$forum[$key]['fup']][$key] = $value;
         }
     }
     $cnimg_1 = array();
     $filetype = is_array($db_uploadfiletype) ? $db_uploadfiletype : unserialize($db_uploadfiletype);
     $default_type = array('gif', 'jpg', 'jpeg', 'bmp', 'png');
     foreach ($default_type as $value) {
         $cnimg_1[$value] = $o_imgsize ? $o_imgsize : $filetype[$value];
     }
     $jsStyle = pwJsonEncode($o_styledb);
     $jsStyleRelation = pwJsonEncode($o_style_relation);
     //list($isheader,$isfooter,$tplname,$isleft) = array(true,true,"m_groups",true);
 } else {
     require_once R_P . 'require/postfunc.php';
     PostCheck(1, $o_groups_gdcheck, $o_groups_qcheck);
     S::gp(array('cname', 'descrip'), 'P');
     S::gp(array('cid', 'firstgradestyle', 'secondgradestyle'), 'P', 2);
     (!$cname || strlen(stripslashes(html_entity_decode($cname, ENT_QUOTES))) > 20) && Showmsg('colony_emptyname');
     $descrip = str_replace('&#61;', '=', $descrip);
     strlen(stripslashes(html_entity_decode($descrip, ENT_QUOTES))) > 255 && Showmsg('colony_descrip');
     //!$cid && Showmsg('colony_class');
     require_once R_P . 'require/bbscode.php';
     $wordsfb = L::loadClass('FilterUtil', 'filter');
     if (($banword = $wordsfb->comprise($cname)) !== false) {
         Showmsg('title_wordsfb');
     }
     if (($banword = $wordsfb->comprise($descrip)) !== false) {
         Showmsg('title_wordsfb');
     }
     $styleid = 0;
Example #8
0
<?php

!function_exists('adminmsg') && exit('Forbidden');
$basename = "{$admin_file}?adminjob=sendmsg";
if (empty($action)) {
    include PrintEot('sendmsg');
    exit;
} elseif ($action == "send") {
    $messageServer = L::loadClass('message', 'message');
    $pwServer['REQUEST_METHOD'] != 'POST' && PostCheck($verify);
    S::gp(array('step', 'by', 'sendto', 'touser', 'subject', 'atc_content'));
    if ($by == 1) {
        !$sendto && adminmsg('mes_send_name_long');
        empty($step) && ($step = 1);
        is_array($sendto) || ($sendto = explode(',', $sendto));
        if ($step == 1) {
            if (empty($subject) || empty($atc_content)) {
                adminmsg('sendmsg_empty');
            }
            $sendGroup = $sendto;
            if (in_array('-1', $sendto)) {
                $query = $db->query("SELECT gid FROM pw_usergroups WHERE gptype='member'");
                while ($rs = $db->fetch_array($query)) {
                    $sendGroup[] = $rs['gid'];
                }
                $sendGroup = array_diff($sendGroup, array('-1'));
            }
            $subject = S::escapeChar($subject);
            $sendmessage = S::escapeChar($atc_content);
            $messageInfo = array('create_uid' => $winduid, 'create_username' => $windid, 'title' => $subject, 'content' => $sendmessage);
            $messageServer->createMessageTasks($sendGroup, $messageInfo);
Example #9
0
                 $arr_logintype[] = $i;
             }
         }
     } else {
         $arr_logintype[0] = 0;
     }
     if (GetCookie('o_invite') && $db_modes['o']['ifopen'] == 1) {
         InitGP(array('jumpurl'));
     } else {
         $jumpurl = $pre_url;
     }
     require_once R_P . 'require/header.php';
     require_once PrintEot('login');
     footer();
 } else {
     PostCheck(0, $db_gdcheck & 2, $loginq, 0);
     require_once R_P . 'require/checkpass.php';
     InitGP(array('pwuser', 'pwpwd', 'question', 'customquest', 'answer', 'cktime', 'hideid', 'jumpurl', 'lgt', 'keepyear'), 'P');
     $jumpurl = str_replace(array('&#61;', '&amp;'), array('=', '&'), $jumpurl);
     if (!$pwuser || !$pwpwd) {
         Showmsg('login_empty');
     }
     $md5_pwpwd = md5($pwpwd);
     $safecv = $db_ifsafecv ? questcode($question, $customquest, $answer) : '';
     //list($winduid, $groupid, $windpwd, $showmsginfo) = checkpass($pwuser, $md5_pwpwd, $safecv, $lgt);
     $logininfo = checkpass($pwuser, $md5_pwpwd, $safecv, $lgt);
     if (!is_array($logininfo)) {
         Showmsg($logininfo);
     }
     list($winduid, $groupid, $windpwd, $showmsginfo) = $logininfo;
     /*update cache*/
Example #10
0
S::gp(array('action'));
!CkInArray($action, array('getback', 'getverify', 'checkverify')) && ($action = 'sendpwd');
//!CkInArray($action ,array('getverify','checkverify')) && require_once(R_P.'require/header.php');;
if ($action == 'sendpwd') {
    if ($_POST['step'] != 2) {
        if ($db_authstate && $db_authgetpwd) {
            $authService = L::loadClass('Authentication', 'user');
            list($authStep, $remainTime, $waitTime, $mobile) = $authService->getStatus('findpwd');
            $authStep_1 = $authStep_2 = 'none';
            ${'authStep_' . $authStep} = '';
            $verifyUsername = $authStep == 1 ? '' : getCookie('findpwd_verifyUsername');
        }
        require_once PrintEot('sendpwd');
        footer();
    } else {
        PostCheck(0, $db_gdcheck & 16);
        S::gp(array('type', 'pwuser', 'email', 'authmobile', 'question', 'customquest', 'answer'));
        $userService = L::loadClass('UserService', 'user');
        /* @var $userService PW_UserService */
        $userarray = $userService->getByUserName($pwuser);
        if ($db_ifsafecv) {
            require_once R_P . 'require/checkpass.php';
            $safecv = questcode($question, $customquest, $answer);
            if ($userarray['safecv'] != $safecv) {
                Showmsg('safecv_error', 1);
            }
        }
        if ($userarray) {
            if ($type == 1) {
                //手机取回
                S::gp(array('authverify', 'new_pwd', 'pwdreapt'));
Example #11
0
     $hasReceiver = true;
 }
 if (empty($step)) {
     if ($hasReceiver && !getstatus($userdb['userstatus'], PW_USERSTATUS_RECEIVEMAIL) && $groupid != '3' && $groupid != '4') {
         Showmsg('sendeamil_refused');
     }
     $to_mail = $hasReceiver ? $userdb['email'] : $db_ceoemail;
     $to_user = $hasReceiver ? $userdb['username'] : '';
     $hiddenmail = 0;
     if ($hasReceiver && !getstatus($userdb['userstatus'], PW_USERSTATUS_PUBLICMAIL) && $groupid != '3' && $groupid != '4') {
         $hiddenmail = 1;
     }
     require_once PrintEot('sendmail');
     footer();
 } else {
     PostCheck(1, $db_gdcheck & 16);
     if ($hasReceiver && !getstatus($userdb['userstatus'], PW_USERSTATUS_RECEIVEMAIL) && $groupid != '3' && $groupid != '4') {
         Showmsg('sendeamil_refused');
     }
     $sendtoemail = $hasReceiver ? $userdb['email'] : $db_ceoemail;
     S::gp(array('subject', 'atc_content', 'fromname', 'fromemail', 'sendtoname'));
     if (empty($subject)) {
         Showmsg('sendeamil_subject_limit');
     }
     if (empty($atc_content) || strlen($atc_content) <= 20) {
         Showmsg('sendeamil_content_limit');
     } elseif (!ereg("^[-a-zA-Z0-9_\\.]+\\@([0-9A-Za-z][0-9A-Za-z-]+\\.)+[A-Za-z]{2,5}\$", $sendtoemail) || !ereg("^[-a-zA-Z0-9_\\.]+\\@([0-9A-Za-z][0-9A-Za-z-]+\\.)+[A-Za-z]{2,5}\$", $fromemail)) {
         Showmsg('illegal_email');
     }
     $userService = L::loadClass('UserService', 'user');
     /* @var $userService PW_UserService */
Example #12
0
        $share['topic']['abstract'] = $replydb['content'];
        $share['topic']['imgs'] = $attimages;
    }
}
/*
* 用户组分享权限
*/
//* include pwCache::getPath(D_P . 'data/bbscache/o_config.php');
pwCache::getData(D_P . 'data/bbscache/o_config.php');
if ($groupid != 3 && $o_share_groups && strpos($o_share_groups, ",{$groupid},") === false) {
    $shareGM = 1;
}
if ($shareGM == 1) {
    Showmsg('share_group_right');
}
PostCheck(true);
/**
* 禁止受限制用户发言
*/
banUser();
$ifhidden != 0 && $ifhidden != 1 && ($ifhidden = 0);
if (!$link) {
    Showmsg('链接地址不能为空');
}
!preg_match("/^https?\\:\\/\\/.{4,255}\$/i", $link) && Showmsg('mode_share_link_error');
if (strlen($descrip) > 300) {
    Showmsg('mode_share_descrip_toolang');
}
require_once R_P . 'require/postfunc.php';
require_once R_P . 'require/bbscode.php';
$wordsfb = L::loadClass('FilterUtil', 'filter');
Example #13
0
         require_once PrintEot('header_login_pop');
         ajax_footer();
     }
 }
 if ($ajax && $ajaxstep == 2) {
     if ($db_gdcheck & 2) {
         $checkCode = GdConfirm(S::getGp('gdcode', 'P'), true);
         !$checkCode && showLoginAjaxMessage('gdcodeerror');
     }
     if ($db_ckquestion & 2) {
         list($qanswer, $questionKey) = array(S::getGp('qanswer', 'P'), S::getGp('qkey', 'P'));
         $checkAnswer = Qcheck($qanswer, $questionKey, true);
         !$checkAnswer && showLoginAjaxMessage('ckquestionerror');
     }
 } else {
     PostCheck(0, $db_gdcheck & 2, $db_ckquestion & 2 && $db_question, 0);
 }
 $jumpurl = str_replace(array('&#61;', '&amp;'), array('=', '&'), $jumpurl);
 if (!$pwuser || !$pwpwd) {
     Showmsg('login_empty');
 }
 $md5_pwpwd = md5($pwpwd);
 $safecv = $db_ifsafecv ? questcode($question, $customquest, $answer) : '';
 $logininfo = checkpass($pwuser, $md5_pwpwd, $safecv, $lgt, true);
 if (!is_array($logininfo)) {
     if ($logininfo == 'login_jihuo') {
         $regEmail = getRegEmail($pwuser);
         ObHeader("{$db_registerfile}?step=finish&email={$regEmail}");
     }
     // defend start
     CloudWind::yunUserDefend('login', CloudWind::getNotLoginUid(), $pwuser, $timestamp, 0, 102, $logininfo, '', '', '');
Example #14
0
    $admin_level = getLangInfo('other', 'admin_level');
    //'manager';
}
$_postdata = $_POST ? PostLog($_POST) : '';
$new_record = '|' . str_replace('|', '&#124;', Char_cv($admin_name)) . '||' . str_replace('|', '&#124;', Char_cv($REQUEST_URI)) . "|{$onlineip}|{$timestamp}|{$_postdata}|\n";
writeover($bbsrecordfile, $new_record, "ab");
if ($pwServer['REQUEST_METHOD'] == 'POST') {
    $referer_a = @parse_url($pwServer['HTTP_REFERER']);
    if ($referer_a['host']) {
        list($http_host) = explode(':', $pwServer['HTTP_HOST']);
        if ($referer_a['host'] != $http_host) {
            adminmsg('undefined_action');
        }
    }
    unset($referer_a);
    PostCheck($verify);
}
unset($_postdata, $new_record, $bbsrecordfile, $dbhost, $dbuser, $dbpw, $dbname, $pconnect, $newmanager, $newmngpwd);
function HtmlConvert(&$array)
{
    if (is_array($array)) {
        foreach ($array as $key => $value) {
            if (!is_array($value)) {
                $array[$key] = htmlspecialchars($value);
            } else {
                HtmlConvert($array[$key]);
            }
        }
    } else {
        $array = htmlspecialchars($array);
    }
Example #15
0
     $diary['privacy'] == '2' && ($disabled = 'disabled');
     $query = $db->query("SELECT * FROM pw_diarytype WHERE uid=" . S::sqlEscape($winduid) . " ORDER BY dtid");
     while ($rs = $db->fetch_array($query)) {
         $selected = '';
         $rs['dtid'] == $diary['dtid'] && ($selected .= 'selected');
         $dtsel .= "<option value=\"{$rs['dtid']}\" {$selected}>{$rs['name']}</option>";
     }
     if (strpos($atc_content, $db_bbsurl) !== false) {
         $atc_content = str_replace('p_w_picpath', $db_picpath, $atc_content);
         $atc_content = str_replace('p_w_upload', $db_attachname, $atc_content);
     }
 } elseif ($_POST['step'] == 2) {
     S::gp(array('did', 'dtid', 'dtided', 'privacy', 'privacyed', 'ifcopy', 'flashatt'), 'P');
     require_once R_P . 'require/bbscode.php';
     require_once R_P . 'require/postfunc.php';
     PostCheck(1, $o_diary_gdcheck, $o_diary_qcheck);
     $wordsfb = L::loadClass('FilterUtil', 'filter');
     if (($banword = $wordsfb->comprise($_POST['atc_title'])) !== false) {
         Showmsg('diary_title_wordsfb');
     }
     if (($banword = $wordsfb->comprise($_POST['atc_content'], false)) !== false) {
         Showmsg('diary_content_wordsfb');
     }
     list($atc_title, $atc_content, $ifconvert, $ifwordsfb) = check_data('modify');
     //$db_tcheck && $winddb['postcheck'] == tcheck($atc_content) && Showmsg('diary_content_same'); //内容验证
     $dtid = (int) $dtid;
     $dtided = (int) $dtided;
     $privacy = (int) $privacy;
     $ifcopy = (int) $ifcopy;
     $ifupload = 0;
     /**
Example #16
0
        $replydb['content'] = strip_tags(convert($replydb['content'], $db_windpost));
        $replydb['content'] = substrs($replydb['content'], 100, 'N');
        $attimages = array();
        $query = $db->query("SELECT attachurl FROM pw_attachs WHERE uid=" . pwEscape($replydb['authorid'], false) . " AND pid=" . pwEscape($id, false) . " AND type='img' LIMIT 5");
        while ($rt = $db->fetch_array($query)) {
            $a_url = geturl($rt['attachurl'], 'show');
            if ($a_url != 'nopic') {
                $attimages[$rt['attachurl']] = is_array($a_url) ? $a_url[0] : $a_url;
            }
        }
        $attimages = serialize($attimages);
        $share['topic']['abstract'] = $replydb['content'];
        $share['topic']['imgs'] = $attimages;
    }
}
PostCheck(1, $o_share_gdcheck, $o_share_qcheck);
/**
* 禁止受限制用户发言
*/
banUser();
$ifhidden != 0 && $ifhidden != 1 && ($ifhidden = 0);
if (!$link) {
    ObHeader('mode.php?m=$m&q=share');
}
!preg_match("/^https?\\:\\/\\/.{4,255}\$/i", $link) && Showmsg('mode_share_link_error');
if (strlen($descrip) > 300) {
    Showmsg('mode_share_descrip_toolang');
}
require_once R_P . 'require/postfunc.php';
require_once R_P . 'require/bbscode.php';
$wordsfb = L::loadClass('FilterUtil');
Example #17
0
         foreach ($o_classdb as $key => $value) {
             $o_cate[$forum[$key]['fup']][$key] = $value;
         }
     }
     $cnimg_1 = array();
     $filetype = is_array($db_uploadfiletype) ? $db_uploadfiletype : unserialize($db_uploadfiletype);
     $default_type = array('gif', 'jpg', 'jpeg', 'bmp', 'png');
     foreach ($default_type as $value) {
         $cnimg_1[$value] = $o_imgsize ? $o_imgsize : $filetype[$value];
     }
     $jsStyle = pwJsonEncode($o_styledb);
     $jsStyleRelation = pwJsonEncode($o_style_relation);
     list($isheader, $isfooter, $tplname, $isleft) = array(true, true, "m_groups", true);
 } else {
     require_once R_P . 'require/postfunc.php';
     PostCheck(1, $o_groups_gdcheck, $o_groups_qcheck && $db_question);
     S::gp(array('cname', 'descrip'), 'P');
     S::gp(array('cid', 'firstgradestyle', 'secondgradestyle'), 'P', 2);
     (!$cname || strlen($cname) > 20) && Showmsg('colony_emptyname');
     $descrip = str_replace('&#61;', '=', $descrip);
     strlen($descrip) > 255 && Showmsg('colony_descrip');
     //!$cid && Showmsg('colony_class');
     require_once R_P . 'require/bbscode.php';
     $wordsfb = L::loadClass('FilterUtil', 'filter');
     if (($banword = $wordsfb->comprise($cname)) !== false) {
         Showmsg('title_wordsfb');
     }
     if (($banword = $wordsfb->comprise($descrip)) !== false) {
         Showmsg('title_wordsfb');
     }
     $styleid = 0;
Example #18
0
 $o_photos_creditset = unserialize($o_photos_creditset);
 $o_photos_creditset['Createalbum'] = @array_diff($o_photos_creditset['Createalbum'], array(0));
 foreach ((array) $o_photos_creditset['Createalbum'] as $key => $value) {
     $moneyName = $credit->cType[$key];
     $unit = $credit->cUnit[$key];
     $creditPops .= $value . $unit . $moneyName . ",";
 }
 $createAlbumCredit = $o_photos_creditset['Createalbum'] ? '创建相册会扣除积分:' . $creditPops . '继续吗?' : '是否确认创建?';
 $createAlbum = $o_photos_creditset['Createalbum'] ? $o_photos_creditset['Createalbum'] : '';
 if (empty($step)) {
     $rt = array();
     $select_0 = 'selected';
     list($isheader, $isfooter, $tplname, $isleft) = array(true, true, "m_photos", true);
 } else {
     require_once R_P . 'require/postfunc.php';
     PostCheck(1, $o_photos_gdcheck, $o_photos_qcheck && $db_question);
     S::gp(array('aname', 'aintro', 'pwd', 'repwd', 'private'));
     if (!$aname) {
         createfail($checkpwd, 'colony_aname_empty');
         Showmsg('colony_aname_empty');
     }
     if (strlen($aname) > 24) {
         createfail($checkpwd, 'colony_aname_toolang');
         Showmsg('colony_aname_toolang');
     }
     if (strlen($aintro) > 255) {
         createfail($checkpwd, 'colony_aintro_toolang');
         Showmsg('colony_aintro_toolang');
     }
     $private = (int) $private;
     if ($private == 3 && !$pwd) {
Example #19
0
    $userService = L::loadClass('UserService', 'user');
    /* @var $userService PW_UserService */
    $reinfo = $userService->get($touid);
    //uid,username
    if ($type == 'birth') {
        $subject = getLangInfo('writemsg', 'birth_title');
        $atc_content = getLangInfo('writemsg', 'birth_content');
    }
    list($bool, $message) = $messageServer->checkReceiver(array($reinfo['username']));
    if (!$bool) {
        Showmsg($message);
    }
    require_once PrintEot('ajax');
    ajax_footer();
} else {
    PostCheck(1, $db_gdcheck & 8);
    S::gp(array('msg_title', 'pwuser'), 'P');
    S::gp(array('atc_content'), 'P', 0);
    $atc_content = S::escapeChar(trim($atc_content));
    if (!$atc_content || !$msg_title || !$pwuser) {
        Showmsg('msg_empty');
    } elseif (strlen($msg_title) > 75 || strlen($atc_content) > 1500) {
        Showmsg('msg_subject_limit');
    }
    if (isset($_G['messagecontentsize']) && $_G['messagecontentsize'] > 0 && strlen($atc_content) > $_G['messagecontentsize']) {
        Showmsg('内容超过限定长度' . $_G['messagecontentsize'] . '字节');
    }
    if ($pwuser == $windid) {
        Showmsg('send_message_to_self');
    }
    require_once R_P . 'require/bbscode.php';
Example #20
0
  * 用户组创建相册权限
  */
 if ($groupid != 3 && $o_photos_groups && strpos($o_photos_groups, ",{$groupid},") === false) {
     createfail($checkpwd, 'photos_group_right');
     Showmsg('photos_group_right');
 }
 if (empty($step)) {
     $rt = array();
     $select_0 = 'selected';
     //require_once(M_P.'require/header.php');
     //require_once PrintEot('m_photos');
     list($isheader, $isfooter, $tplname, $isleft) = array(true, true, "m_photos", true);
     //footer();
 } else {
     require_once R_P . 'require/postfunc.php';
     PostCheck(1, $o_photos_gdcheck, $o_photos_qcheck);
     InitGP(array('aname', 'aintro', 'pwd', 'repwd', 'private'));
     if (!$aname) {
         createfail($checkpwd, 'colony_aname_empty');
         Showmsg('colony_aname_empty');
     }
     if (strlen($aname) > 24) {
         createfail($checkpwd, 'colony_aname_toolang');
         Showmsg('colony_aname_toolang');
     }
     if (strlen($aintro) > 255) {
         createfail($checkpwd, 'colony_aintro_toolang');
         Showmsg('colony_aintro_toolang');
     }
     $private = (int) $private;
     if ($private == 3 && !$pwd) {
Example #21
0
            }
        }
        ksort($icondb);
        @closedir($emotion);
    }
    //multiple post types
    if ($foruminfo['allowtype'] && ($foruminfo['allowtype'] & 1 || $foruminfo['allowtype'] & 2 && $_G['allownewvote'] || $foruminfo['allowtype'] & 4 && $_G['allowactive'] || $foruminfo['allowtype'] & 8 && $_G['allowreward'] || $foruminfo['allowtype'] & 16 || $foruminfo['allowtype'] & 32 && $_G['allowdebate'])) {
        $N_allowtypeopen = true;
    } else {
        $N_allowtypeopen = false;
    }
} else {
    if ($db_cloudgdcode && defined('AJAX') && S::inArray($action, array('reply', 'quote'))) {
        $keepCloudCaptchaCode = true;
    }
    PostCheck(1, $db_gdcheck & 4 && (!$db_postgd || $winddb['postnum'] < $db_postgd), $db_ckquestion & 4 && (!$postq || $winddb['postnum'] < $postq) && $db_question);
    !$windid && ($windid = '游客');
    /*
    if ($db_xforwardip && $_POST['_hexie'] != GetVerify($onlineip.$winddb['regdate'].$fid.$tid)) {
    	Showmsg('undefined_action');
    }
    */
}
//默认动漫表情处理
if ($db_windmagic && ($action == 'new' || $action == 'modify' && $pid == 'tpc')) {
    $mDef = '';
    //* @include_once pwCache::getPath(D_P."data/bbscache/myshow_default.php");
    pwCache::getData(D_P . "data/bbscache/myshow_default.php");
}
if ($action == "new") {
    require_once R_P . 'require/postnew.php';