• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP stripWindCode函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: topicPost

 function topicPost($tid, $postdata)
 {
     global $timestamp, $winduid, $windid;
     if (!$this->info) {
         return false;
     }
     $this->_db->update("INSERT INTO pw_argument SET " . S::sqlSingle(array('tid' => $tid, 'cyid' => $this->info['id'], 'postdate' => $timestamp, 'lastpost' => $timestamp)));
     if ($postdata['ifcheck'] > 0) {
         require_once R_P . 'u/require/core.php';
         //tnum加一
         //* $this->_db->update("UPDATE pw_colonys SET tnum=tnum+'1',pnum=pnum+'1',todaypost=todaypost+'1' WHERE id=" . S::sqlEscape($this->cyid));
         $this->_db->update(pwQuery::buildClause("UPDATE :pw_table SET tnum=tnum+1,pnum=pnum+1,todaypost=todaypost+1 WHERE id=:id", array('pw_colonys', $this->cyid)));
         $this->info['tnum']++;
         $this->info['pnum']++;
         updateGroupLevel($this->cyid, $this->info);
         if ($this->info['ifopen']) {
             $weiboService = L::loadClass('weibo', 'sns');
             /* @var $weiboService PW_Weibo */
             $weiboContent = substrs(stripWindCode($postdata['content']), 125);
             $weiboExtra = array('cyid' => $this->cyid, 'title' => stripslashes($postdata['title']), 'cname' => $this->info['cname']);
             $weiboService->send($winduid, $weiboContent, 'group_article', $tid, $weiboExtra);
         }
     }
     //更新群成员表里面的最后发言时间
     $this->_db->update("UPDATE pw_cmembers SET lastpost=" . S::sqlEscape($timestamp) . " WHERE uid=" . S::sqlEscape($winduid));
 }
开发者ID:jechiy,项目名称:PHPWind,代码行数:26,代码来源:colonypost.class.php


示例2: getSourceData

 function getSourceData($sourceId)
 {
     $data = $this->_getDiaryData($sourceId);
     if (!$data) {
         return array();
     }
     $data['descrip'] = substrs(stripWindCode($data['content']), 100);
     $data['frominfo'] = 'хуж╬';
     $data['author'] = $data['username'];
     return $data;
 }
开发者ID:sherlockhouse,项目名称:aliyun,代码行数:11,代码来源:diarysourcetype.class.php


示例3: getSourceData

 function getSourceData($sourceId)
 {
     $data = $this->_getThreadData($sourceId);
     if (!$data || $this->_checkIfDelete($data)) {
         return array();
     }
     $data['content'] = preg_replace("/\\[attachment=[0-9]+\\]/is", '', $data['content']);
     $data['descrip'] = substrs(stripWindCode($data['content']), 100);
     $data['frominfo'] = 'ÂÛ̳';
     return $data;
 }
开发者ID:sherlockhouse,项目名称:aliyun,代码行数:11,代码来源:threadsourcetype.class.php


示例4: _cookData

 function _cookData($data)
 {
     global $db_bbsurl;
     $data['url'] = $db_bbsurl . '/apps.php?q=group&cyid=' . $data['id'];
     $data['title'] = $data['cname'];
     $data['image'] = $this->_getGroupImage($data['cnimg']);
     $data['descrip'] = substrs(strip_tags(stripWindCode($data['descrip'])), 100);
     if ($data['credit']) {
         $data['credit'] = (int) $data['credit'];
     }
     return $data;
 }
开发者ID:jechiy,项目名称:PHPWind,代码行数:12,代码来源:groupsource.class.php


示例5: set_summary

 /**
  * @param $_summary the $_summary to set
  */
 function set_summary($_summary, $convert)
 {
     if ($_summary) {
         $_summary = stripWindCode($_summary);
         $_summary = strip_tags($_summary);
         $_summary = str_replace(array('"', "\n", "\r", ' ', '&', '<', '', ' '), '', $_summary);
         $_summary = substrs($_summary, 255);
         if ($convert) {
             $wordsfb = L::loadClass('FilterUtil');
             $_summary = $wordsfb->convert($_summary);
         }
         $this->_summary = trim($_summary);
     }
 }
开发者ID:adi00,项目名称:wumaproject,代码行数:17,代码来源:seoset.class.php


示例6: getDescripByTid

function getDescripByTid($tid)
{
    global $db;
    $tid = (int) $tid;
    if (!$tid) {
        return '';
    }
    $table = GetTtable($tid);
    $content = $db->get_value("SELECT content FROM {$table} WHERE tid=" . S::sqlEscape($tid));
    $content = preg_replace("/<((style|script).*?)>(.*?)<(\\/\\1.*?)>/si", "", $content);
    $content = strip_tags(stripWindCode($content));
    $content = trim($content);
    return substrs($content, 200);
}
开发者ID:jechiy,项目名称:PHPWind,代码行数:14,代码来源:functions.php


示例7: _getContentANDSubjectByDiary

 /**
  * 有条件处理日志内容和标题
  *
  * @param array() 	$data		日志数据
  * @param bool 		$islist		是否是列表,列表页日志内容显示字节
  */
 function _getContentANDSubjectByDiary($data, $islist = false, $isFilterFace = false)
 {
     global $groupid, $db_shield, $db_windpost, $o_shownum;
     $result = array();
     if ($data['groupid'] == 6 && $db_shield && $groupid != 3) {
         $data['subject'] = '';
         $data['content'] = appShield('ban_diary');
     }
     $wordsService = $this->_serviceFactory('FilterUtil', 'filter');
     /* @var $wordsService PW_FilterUtil */
     if (!$wordsService->equal($data['ifwordsfb'])) {
         $data['content'] = $wordsService->convert($data['content'], array('id' => $data['did'], 'type' => 'diary', 'code' => $data['ifwordsfb']));
     }
     $isFilterFace == true && ($data['content'] = preg_replace("/\\[s:(.+?)\\]/eis", '', $data['content']));
     require_once R_P . 'require/bbscode.php';
     $data['ifconvert'] == 2 && ($data['content'] = convert($data['content'], $db_windpost));
     if ($islist) {
         $data['content'] = strip_tags($data['content']);
         $data['content'] = stripWindCode($this->escapeStr($data['content']));
         $o_shownum && ($data['content'] = substrs($data['content'], $o_shownum));
     }
     $data['content'] = preg_replace('/\\[upload=(\\d+)\\]/Ui', "", $data['content']);
     $data['content'] = str_replace("\n", "<br />", $data['content']);
     $result = array($data['subject'], $data['content']);
     return $result;
 }
开发者ID:sherlockhouse,项目名称:aliyun,代码行数:32,代码来源:diary.class.php


示例8: wap_clscode

function wap_clscode($string)
{
    return stripWindCode($string);
}
开发者ID:jechiy,项目名称:PHPWind,代码行数:4,代码来源:wap_mod.php


示例9: forum_sell

}
if (!$admincheck && $foruminfo['forumsell']) {
    forum_sell($fid);
}
if ($read['ifcheck'] == 0 && !$isGM && $windid != $read['author'] && !pwRights($isBM, 'viewcheck')) {
    Showmsg('read_check');
}
if ($read['locked'] % 3 == 2 && !$isGM && !pwRights($isBM, 'viewclose')) {
    Showmsg('read_locked');
}
$db_metakeyword = substr($read['tags'], 0, strpos($read['tags'], "\t"));
$db_metakeyword = (empty($db_metakeyword) ? $subject : $db_metakeyword) . ',' . $forumtitle;
$db_metakeyword = trim(str_replace(array('|', ' - ', "\t", ' ', ',,,', ',,'), ',', $db_metakeyword), ',');
if ($groupid == 'guest' && !$read['ifshield'] && !isban($read, $fid)) {
    if ($read['ifconvert'] == 2) {
        $metadescrip = stripWindCode($read['content']);
        $metadescrip = strip_tags($metadescrip);
    } else {
        $metadescrip = strip_tags($read['content']);
    }
    $metadescrip = str_replace(array('"', "\n", "\r", '&nbsp;', '&amp;', '&lt;', '', '&#160;'), '', $metadescrip);
    $metadescrip = substrs($metadescrip, 255, false);
    if ($read['ifwordsfb'] != $db_wordsfb) {
        //$metadescrip = wordsfb($metadescrip,$read['ifwordsfb']);
        $wordsfb = L::loadClass('FilterUtil', 'filter');
        $metadescrip = $wordsfb->convert($metadescrip);
    }
    if (trim($metadescrip)) {
        $db_metadescrip = $metadescrip;
    }
    unset($metadescrip, $tmpAllow);
开发者ID:jechiy,项目名称:PHPWind,代码行数:31,代码来源:mod_read.php


示例10: IN

     $sqltab .= ' LEFT JOIN pw_cmembers cm ON c.id=cm.colonyid';
     $sqlsel .= ' AND cm.uid IN(' . S::sqlImplode($uids) . ')';
 }
 $total = $db->get_value("SELECT COUNT(DISTINCT c.id) AS sum FROM pw_colonys c {$sqltab} WHERE 1 {$sqlsel}");
 if ($total) {
     require_once R_P . 'require/bbscode.php';
     list($pages, $limit) = pwLimitPages($total, $page, "group.php?q=all" . ($members ? "&members={$members}" : '') . ($isFriends ? "&friends={$isFriends}" : '') . "&keyword=" . rawurlencode($keyword) . "&" . ($styleid ? "styleid=" . $styleid : "") . "&");
     $query = $db->query("SELECT DISTINCT c.* FROM pw_colonys c {$sqltab} WHERE 1 {$sqlsel} ORDER BY c.id DESC {$limit}");
     while ($rt = $db->fetch_array($query)) {
         if ($rt['cnimg']) {
             list($rt['cnimg']) = geturl("cn_img/{$rt['cnimg']}", 'lf');
         } else {
             $rt['cnimg'] = $GLOBALS['imgpath'] . '/g/groupnopic.gif';
         }
         $rt['cname'] = str_replace($keyword, '<font color="#FF0000">' . $keyword . '</font>', $rt['cname']);
         $rt['descrip'] = str_replace($keyword, '<font color="#FF0000">' . $keyword . '</font>', stripWindCode($rt['descrip']));
         $rt['colonyNums'] = PwColony::calculateCredit($rt);
         $rt['createtime'] = get_date($rt['createtime'], 'Y-m-d');
         $group[$rt['id']] = $rt;
     }
 }
 $colonyids = S::sqlImplode(array_keys($group));
 if ($colonyids) {
     $query = $db->query("SELECT id,ifadmin,colonyid FROM pw_cmembers WHERE colonyid IN ({$colonyids}) AND uid=" . S::sqlEscape($winduid, false));
     while ($rt = $db->fetch_array($query)) {
         $cMembers[$rt['colonyid']] = $rt['ifadmin'];
     }
 }
 $u = $winduid;
 $username = $windid;
 /*
开发者ID:sherlockhouse,项目名称:aliyun,代码行数:31,代码来源:group.php


示例11: IN

         }
         $description = "Latest {$Rss_newnum} article of all forums";
         if ($fids) {
             $sql = "WHERE fid IN({$fids}) AND ifcheck=1 AND topped='0' AND postdate>" . pwEscape($timestamp - 604800) . " ORDER BY postdate DESC LIMIT {$Rss_newnum}";
             $forceindex = 'FORCE INDEX (postdate)';
         }
     }
     $channel = array('title' => $db_bbsname, 'link' => $db_bbsurl, 'description' => $description, 'copyright' => "Copyright(C) {$db_bbsname}", 'generator' => "PHPWind Forums by PHPWind Studio", 'lastBuildDate' => date('r'));
     $image = array('url' => "{$imgpath}/{$stylepath}/rss.gif", 'title' => 'PHPWind Board', 'link' => $db_bbsurl, 'description' => $db_bbsname);
     $Rss = new Rss(array('xml' => "1.0", 'rss' => "2.0", 'encoding' => $db_charset));
     $Rss->channel($channel);
     $Rss->image($image);
     if ($sql) {
         $query = $db->query("SELECT t.tid,t.fid,t.subject,t.author,t.postdate,t.anonymous,tm.content FROM pw_threads t {$forceindex} RIGHT JOIN {$pw_tmsgs} tm ON tm.tid=t.tid {$sql}");
         while ($rt = $db->fetch_array($query)) {
             $rt['content'] = substrs(stripWindCode($rt['content']), 300);
             $rt['anonymous'] && ($rt['author'] = $db_anonymousname);
             if ($db_htmifopen) {
                 $link = "{$db_bbsurl}/read{$db_dir}tid-{$rt['tid']}{$db_ext}";
             } else {
                 $link = "{$db_bbsurl}/read.php?tid={$rt['tid']}";
             }
             $item = array('title' => $rt['subject'], 'description' => $rt['content'], 'link' => $link, 'author' => $rt['author'], 'category' => $forum[$rt['fid']]['name'], 'pubdate' => date('r', $rt['postdate']));
             $Rss->item($item);
         }
     }
     $Rss->generate($cache_path);
 }
 header("Content-type: application/xml");
 @readfile($cache_path);
 exit;
开发者ID:adi00,项目名称:wumaproject,代码行数:31,代码来源:rss.php


示例12: getColonyThread

 function getColonyThread($tid)
 {
     $pw_tmsgs = GetTtable($tid);
     $rt = $this->_db->get_one("SELECT a.cyid,t.tid,t.subject,t.fid,t.ptable,tm.content,c.cname FROM pw_argument a left join pw_threads t ON a.tid=t.tid LEFT JOIN {$pw_tmsgs} tm ON t.tid=tm.tid LEFT JOIN pw_colonys c ON a.cyid=c.id WHERE a.tid=" . pwEscape($tid));
     return $rt ? array('content' => substrs(stripWindCode($rt['content']), 125), 'type' => 40, 'objectid' => $rt['tid'], 'extra' => array('title' => $rt['subject'], 'cyid' => $rt['cyid'], 'cname' => $rt['cname'])) : array();
 }
开发者ID:sherlockhouse,项目名称:aliyun,代码行数:6,代码来源:weibo.php


示例13: _buildGroups

 function _buildGroups($groups, $keywords)
 {
     if (!$groups) {
         return array();
     }
     $result = array();
     $keywords = $keywords ? explode(",", $keywords) : array();
     foreach ($groups as $group) {
         $group['id'] = $group['id'];
         $group['createtime'] = get_date($group['createtime'], "Y-m-d H:i");
         $group['descrip'] = substrs(stripWindCode(strip_tags($group['descrip'])), 100);
         $group['credit'] = $this->_calculateCredit($group);
         $group['sname'] = $group['sname'] ? $group['sname'] : '末分类';
         foreach ($keywords as $keyword) {
             $keyword && ($group['cname'] = $this->_highlighting($keyword, $group['cname']));
             $keyword && ($group['descrip'] = $this->_highlighting($keyword, $group['descrip']));
         }
         if ($group['cnimg']) {
             list($group['cnimg']) = geturl("cn_img/" . $group['cnimg'], 'lf');
         } else {
             $group['cnimg'] = "images/search/group.png";
         }
         $result[] = $group;
     }
     return $result;
 }
开发者ID:jechiy,项目名称:PHPWind,代码行数:26,代码来源:base.search.php


示例14: array_keys

     $uids = $friends ? array_keys($friends) : array(0);
     $sqltab .= ' LEFT JOIN pw_cmembers cm ON c.id=cm.colonyid';
     $sqlsel .= ' AND cm.uid IN(' . S::sqlImplode($uids) . ')';
 }
 $total = $db->get_value("SELECT COUNT(DISTINCT c.id) AS sum FROM pw_colonys c {$sqltab} WHERE 1 {$sqlsel}");
 if ($total) {
     require_once R_P . 'require/bbscode.php';
     list($pages, $limit) = pwLimitPages($total, $page, "{$basename}a=all&keyword=" . rawurlencode($keyword) . "&" . ($styleid ? "styleid=" . $styleid : "") . "&");
     $query = $db->query("SELECT DISTINCT c.* FROM pw_colonys c {$sqltab} WHERE 1 {$sqlsel} ORDER BY c.id DESC {$limit}");
     while ($rt = $db->fetch_array($query)) {
         if ($rt['cnimg']) {
             list($rt['cnimg']) = geturl("cn_img/{$rt['cnimg']}", 'lf');
         } else {
             $rt['cnimg'] = $GLOBALS['imgpath'] . '/g/groupnopic.gif';
         }
         $rt['descrip'] = stripWindCode($rt['descrip']);
         $rt['colonyNums'] = PwColony::calculateCredit($rt);
         $rt['createtime'] = get_date($rt['createtime'], 'Y-m-d');
         $group[$rt['id']] = $rt;
     }
 }
 $colonyids = S::sqlImplode(array_keys($group));
 if ($colonyids) {
     $query = $db->query("SELECT id,ifadmin,colonyid FROM pw_cmembers WHERE colonyid IN ({$colonyids}) AND uid=" . S::sqlEscape($winduid, false));
     while ($rt = $db->fetch_array($query)) {
         $cMembers[$rt['colonyid']] = $rt['ifadmin'];
     }
 }
 $u = $winduid;
 $username = $windid;
 /*
开发者ID:jechiy,项目名称:PHPWind,代码行数:31,代码来源:m_groups.php


示例15: getLatestImgThread

 function getLatestImgThread($fids, $offset, $limit)
 {
     list($fids, $offset, $limit) = array($fids ? explode(',', $fids) : array(), intval($offset), intval($limit));
     global $attachpath;
     $tmpData = $result['threads'] = $tmpThreadInfos = array();
     $sqlLimit = $offset > 0 ? ' AND tid < ' . intval($offset) : '';
     $fidLimit = S::isArray($fids) ? ' AND fid IN (' . S::sqlImplode($fids) . ') ' : '';
     $result['count'] = intval($GLOBALS['db']->get_value("SELECT COUNT(distinct tid) as count FROM pw_attachs WHERE `pid`=0 AND `did`=0 AND `type`='img' {$fidLimit}"));
     if ($result['count'] > 0) {
         $query = $GLOBALS['db']->query("SELECT tid,attachurl,ifthumb,count(attachurl) as count FROM pw_attachs WHERE `pid`=0 AND `did`=0 AND `type`='img' {$sqlLimit} {$fidLimit} GROUP BY tid ORDER BY uploadtime DESC LIMIT " . intval($limit));
         while ($rt = $GLOBALS['db']->fetch_array($query)) {
             $rt['tid'] > 0 && ($tmpData[$rt['tid']]['picurl'] = current($this->getCustomizedCommonService()->getAttachWithThumblist(array($rt))));
             $rt['tid'] > 0 && ($tmpData[$rt['tid']]['piccount'] = $rt['count']);
         }
     }
     if (count($tmpData) > 0) {
         $tmpThreadInfos = $this->getThreadsByTids(array_filter(array_unique(array_keys($tmpData))));
         foreach ($tmpData as $tid => $value) {
             $tmpResult = isset($tmpThreadInfos[$tid]) ? $tmpThreadInfos[$tid] : array();
             if (isset($tmpResult['content'])) {
                 $tmpResult['content'] = preg_replace('|\\[attachment=\\d+\\]|i', '', $tmpResult['content']);
                 $tmpResult['content'] = strip_tags(stripWindCode($tmpResult['content']));
             }
             $tmpData[$tid] = array_merge($value, $tmpResult);
         }
     }
     $result['threads'] = $tmpData;
     return $this->buildResponse(0, $result);
 }
开发者ID:sherlockhouse,项目名称:aliyun,代码行数:29,代码来源:ver.customized.thread.php


示例16: elseif

             $rt['image'] = $temp['photo']['image'];
             $temp_uid = $temp['photo']['uid'];
             $rt['title'] = $belong . "<a href=\"u.php?uid={$temp_uid}\" target=\"_blank\">" . $temp['photo']['username'] . "</a>";
         } elseif ($rt['type'] == 'album') {
             $belong = getLangInfo('app', 'photo_belong');
             $rt['image'] = $temp['album']['image'];
             $temp_uid = $temp['album']['uid'];
             $rt['title'] = $belong . "<a href=\"u.php?uid={$temp_uid}\" target=\"_blank\">" . $temp['album']['username'] . "</a>";
         } elseif ($rt['type'] == 'group') {
             $rt['image'] = $temp['group']['image'];
             $rt['title'] = "<a href=\"{$rt['link']}\" target=\"_blank\">" . $temp['group']['name'] . "</a>";
         } elseif ($rt['type'] == 'diary') {
             $rt['title'] = "<a href=\"{$rt['link']}\" target=\"_blank\">" . $temp['diary']['subject'] . "</a>";
         } elseif ($rt['type'] == 'topic') {
             $rt['title'] = "<a href=\"{$rt['link']}\" target=\"_blank\">" . $temp['topic']['subject'] . "</a>";
             $rt['abstract'] = stripWindCode($temp['topic']['abstract']);
             $rt['imgs'] = unserialize($temp['topic']['imgs']);
         } else {
             $rt['title'] = "<a href=\"{$rt['link']}\" target=\"_blank\">" . substrs($rt['link'], 40) . "</a>";
         }
         $rt['descrip'] = $temp['descrip'];
         if ($rt['ifhidden']) {
             $rt['type_name'] = getLangInfo('app', $rt['type'] . '_self');
         } else {
             $rt['type_name'] = getLangInfo('app', $rt['type']);
         }
         list($rt['icon']) = showfacedesign($rt['icon'], 1);
         unset($rt['content']);
         $shares[] = $rt;
     }
 }
开发者ID:adi00,项目名称:wumaproject,代码行数:31,代码来源:m_share.php


示例17: newPicUpdate

 /**
  * new reply update
  *
  * @param int $tid
  * @param int $fid
  * @param string $postdate
  * @return
  */
 function newPicUpdate($aid, $fid, $tid, $addition, $ifthumb = 0, $atc_content)
 {
     if (!($this->ifcache & 512)) {
         return false;
     }
     $ifthumb = (int) $ifthumb;
     $atc_content = substrs(stripWindCode($atc_content), 30);
     $additions = array('0' => $addition, '1' => $atc_content);
     $addition = addslashes(serialize($additions));
     $this->updatelist[] = array('newpic', $fid, $tid, $aid, $addition, $ifthumb);
     $this->updatetype['newpic'] = 1;
     return true;
 }
开发者ID:sherlockhouse,项目名称:aliyun,代码行数:21,代码来源:elementupdate.class.php


示例18: IN

 $db->update("UPDATE pw_diarytype SET num=num+1 WHERE uid=" . S::sqlEscape($winduid) . " AND dtid=" . S::sqlEscape($dtid));
 //更新分类日志数
 if ($aids) {
     $diaryService = L::loadClass('Diary', 'diary');
     $diaryService->updateDiaryContentByAttach($did, $attachIds);
     $db->update("UPDATE pw_attachs SET did=" . S::sqlEscape($did) . " WHERE aid IN(" . S::sqlImplode($aids) . ")");
     $pwInfoSQL = array('uploadtime' => $winddb['uploadtime'], 'uploadnum' => $winddb['uploadnum']);
 }
 if (!$privacy && !$myAppsData['index_privacy'] && !$myAppsData['diary_privacy']) {
     $userCache = L::loadClass('Usercache', 'user');
     $userCache->delete($winduid, 'carddiary');
     updateDatanalyse($did, 'diaryNew', $timestamp);
     if ($sendWeiboPrivacy && $ifsendweibo) {
         $weiboService = L::loadClass('weibo', 'sns');
         /* @var $weiboService PW_Weibo */
         $atc_content = substrs(stripWindCode($weiboService->escapeStr($atc_content)), 125);
         $weiboExtra = array('did' => $did, 'title' => stripslashes($atc_title));
         $weiboService->send($winduid, $atc_content, 'diary', $did, $weiboExtra);
     }
 }
 countPosts('+1');
 //积分变动
 require_once R_P . 'require/credit.php';
 $o_diary_creditset = unserialize($o_diary_creditset);
 $creditset = getCreditset($o_diary_creditset['Post']);
 $creditset = array_diff($creditset, array(0));
 if (!empty($creditset)) {
     $credit->sets($winduid, $creditset, true);
     updateMemberid($winduid);
 }
 if ($creditlog = unserialize($o_diary_creditlog)) {
开发者ID:sherlockhouse,项目名称:aliyun,代码行数:31,代码来源:my.php


示例19: pwEscape

 $db->update("INSERT INTO pw_diary SET {$pwSQL}");
 $did = $db->insert_id();
 $db->update("UPDATE pw_diarytype SET num=num+1 WHERE uid=" . pwEscape($winduid) . " AND dtid=" . pwEscape($dtid));
 //更新分类日志数
 if ($aids) {
     $db->update("UPDATE pw_attachs SET did=" . pwEscape($did) . " WHERE aid IN({$aids})");
 }
 if ($privacy != 2) {
     pwAddFeed($winduid, 'diary', $did, array('lang' => 'diary_data', 'username' => $windid, 'uid' => $winduid, 'did' => $did, 'subject' => $atc_title));
 }
 countPosts('+1');
 if (!$privacy) {
     //会员资讯缓存
     $usercachedata = array();
     $usercache = L::loadDB('Usercache');
     $usercachedata['content'] = substrs(stripWindCode($atc_content), 100, N);
     $usercachedata['subject'] = $atc_title;
     $usercachedata['postdate'] = $timestamp;
     if ($attachs) {
         foreach ($attachs as $value) {
             if ($value['type'] == 'img') {
                 $usercachedata['attimages'][] = array('attachurl' => $value['attachurl'], 'ifthumb' => $value['ifthumb']);
             }
         }
     }
     $usercache->update($winduid, 'diary', $did, $usercachedata);
 }
 //积分变动
 require_once R_P . 'require/credit.php';
 $o_diary_creditset = unserialize($o_diary_creditset);
 $creditset = getCreditset($o_diary_creditset['Post']);
开发者ID:adi00,项目名称:wumaproject,代码行数:31,代码来源:index.php


示例20: array

    return;
}
// 站点是否绑定该类型
$weiboSiteBindService = L::loadClass('WeiboSiteBindService', 'sns/weibotoplatform/service');
if (!$weiboSiteBindService->isBind($type)) {
    return;
}
$db_bbsurl .= "/";
if ($tid) {
    // 取帖子内容
    //$threads = L::loadClass('Threads', 'forum');
    //$read = $threads->getByThreadId($tid);
    $read = $db->get_one("SELECT t.* ,tm.* FROM pw_threads t LEFT JOIN " . S::sqlMetadata(GetTtable($tid)) . " tm ON t.tid=tm.tid WHERE t.tid=" . S::sqlEscape($tid));
    if (!empty($read)) {
        $sinaWeiboContentTranslator = L::loadClass('SinaWeiboContentTranslator', 'sns/weibotoplatform/');
        $shareContent = $sinaWeiboContentTranslator->translate('article', array('content' => preg_replace(array('/(&nbsp;){1,}/', '/( ){1,}/'), array(' ', ' '), substrs(stripWindCode(str_replace("\n", " ", strip_tags($read['content']))), 100)), 'objectid' => $tid), array('title' => $read['subject']));
        $title = urlencode(pwConvert($shareContent, 'UTF8', $db_charset));
        $query = $db->query("SELECT aid,attachurl,pid,type,ifthumb FROM pw_attachs WHERE pid=0 AND tid=" . S::sqlEscape($tid));
        $attachImg = '';
        while ($rt = $db->fetch_array($query)) {
            if ($rt['type'] != 'img') {
                continue;
            }
            $tmpUrl = geturl($rt['attachurl'], $rt['ifthumb']);
            if (is_array($tmpUrl)) {
                $attachImg[] = false !== strpos($tmpUrl[0], 'http://') ? $tmpUrl[0] : $db_bbsurl . $tmpUrl[0];
            }
        }
        $photoCount = count($attachImg);
    }
}
开发者ID:jechiy,项目名称:PHPWind,代码行数:31,代码来源:share.php



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP strip_accents函数代码示例发布时间:2022-05-23
下一篇:
PHP stripTagsFull函数代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap