当前位置: 首页>>代码示例>>PHP>>正文


PHP Char_cv函数代码示例

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


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

示例1: SendAppmsg

 function SendAppmsg($toname, $fromname, $subject, $content)
 {
     $msg = array('toUser' => $toname, 'fromUid' => '-1', 'fromUser' => $fromname, 'subject' => Char_cv(stripslashes($subject)), 'content' => Char_cv(stripslashes($content)));
     require_once R_P . 'require/msg.php';
     pwSendMsg($msg);
     return new ApiResponse(true);
 }
开发者ID:adi00,项目名称:wumaproject,代码行数:7,代码来源:class_Msg.php

示例2: initCurrUpload

 function initCurrUpload($key, $value)
 {
     list($t, $i) = explode('_', $key);
     $arr = array('id' => intval($i), 'attname' => $t, 'name' => Char_cv($value['name']), 'size' => intval($value['size']), 'type' => 'zip', 'ifthumb' => 0, 'fileuploadurl' => '');
     $arr['ext'] = strtolower(substr(strrchr($arr['name'], '.'), 1));
     return $arr;
 }
开发者ID:adi00,项目名称:wumaproject,代码行数:7,代码来源:upload.class.php

示例3: PW_Appclient

 function PW_Appclient()
 {
     global $db_siteappkey, $timestamp, $db_sitehash, $db_siteownerid, $db_siteid, $db_bbsurl, $db_charset, $db_appifopen, $db_appbbs, $db_appo, $pwServer;
     $db_bbsurl = Char_cv("http://" . $pwServer['HTTP_HOST'] . substr($pwServer['PHP_SELF'], 0, strrpos($pwServer['PHP_SELF'], '/')));
     if (!file_exists(D_P . "data/bbscache/forum_appinfo.php")) {
         require_once R_P . "admin/cache.php";
         updatecache_f();
     }
     @(include_once D_P . "data/bbscache/forum_appinfo.php");
     $this->_db = $GLOBALS['db'];
     $this->appkey = $db_siteappkey;
     $this->timestamp = time();
     $this->sitehash = $db_sitehash;
     $this->siteownerid = $db_siteownerid;
     $this->siteid = $db_siteid;
     $this->bbsurl = $db_bbsurl;
     $this->charset = $db_charset;
     $this->appifopen = $db_appifopen;
     $this->appbbs = $db_appbbs;
     $this->appo = $db_appo;
     $this->_appsdb = array();
     $this->_app_array = array();
     $this->_appslist = $this->getApplist();
     $this->appinfo = $forum_appinfo;
 }
开发者ID:adi00,项目名称:wumaproject,代码行数:25,代码来源:appclient.class.php

示例4: reply

 function reply($mid, $subject, $message)
 {
     global $_USERS;
     $mid = GetNum($mid);
     $temparray = $this->getone($mid);
     $addarray = array('fromuid' => $_USERS['uid'], 'fromuname' => $_USERS['uname'], 'touid' => $temparray['fromuid'], 'touname' => $temparray['fromuname'], 'type' => 2, 'subject' => Char_cv($subject), 'sendtime' => time(), 'writetime' => time(), 'hasview' => 0, 'isadmin' => 0, 'message' => Char_cv($message));
     return $this->add($addarray);
 }
开发者ID:GHubgenius,项目名称:julianufo-project-daigou,代码行数:8,代码来源:pm.class.php

示例5: writetoollog

function writetoollog($log)
{
    global $db, $db_bbsurl;
    $log['type'] = getLangInfo('toollog', $log['type']);
    $log['filename'] = Char_cv($log['filename']);
    $log['username'] = Char_cv($log['username']);
    $log['descrip'] = Char_cv(getLangInfo('toollog', $log['descrip'], $log));
    $db->update("INSERT INTO pw_toollog SET " . pwSqlSingle(array('type' => $log['type'], 'filename' => $log['filename'], 'nums' => $log['nums'], 'money' => $log['money'], 'descrip' => $log['descrip'], 'uid' => $log['uid'], 'touid' => $log['touid'], 'username' => $log['username'], 'ip' => $log['ip'], 'time' => $log['time'])));
}
开发者ID:adi00,项目名称:wumaproject,代码行数:9,代码来源:tool.php

示例6: add

 function add($uid, $appid, $appname, $allowfeed, $descrip)
 {
     global $timestamp;
     $this->db->query_unbuffered("REPLACE INTO " . UC_DBTABLEPRE . "userapp SET " . pwSqlSingle(array('uid' => $uid, 'appid' => $appid, 'appname' => $appname, 'allowfeed' => $allowfeed)));
     if ($allowfeed) {
         $descrip = Char_cv($descrip);
         $this->db->query_unbuffered("INSERT INTO " . UC_DBTABLEPRE . "feed SET " . pwSqlSingle(array('uid' => $uid, 'type' => 'app', 'descrip' => $descrip, 'timestamp' => $timestamp), false));
     }
     return new ApiResponse(true);
 }
开发者ID:noikiy,项目名称:ecmall,代码行数:10,代码来源:class_UserApp.php

示例7: writeforumlog

function writeforumlog($log)
{
    $log['username1'] = Char_cv($log['username1']);
    $log['username2'] = Char_cv($log['username2']);
    $log['field1'] = Char_cv($log['field1']);
    $log['field2'] = Char_cv($log['field2']);
    $log['field3'] = Char_cv($log['field3']);
    $log['descrip'] = Char_cv(getLangInfo('log', $log['descrip'], $log));
    $GLOBALS['db']->update("INSERT INTO pw_forumlog SET " . pwSqlSingle(array('type' => $log['type'], 'username1' => $log['username1'], 'username2' => $log['username2'], 'field1' => $log['field1'], 'field2' => $log['field2'], 'field3' => $log['field3'], 'descrip' => $log['descrip'], 'timestamp' => $log['timestamp'], 'ip' => $log['ip']), false));
}
开发者ID:adi00,项目名称:wumaproject,代码行数:10,代码来源:writelog.php

示例8: publishTemplatizedAction

 function publishTemplatizedAction($uid, $descrip, $appid)
 {
     //插入动态信息
     global $timestamp;
     $rt = $this->db->get_one("SELECT allowfeed FROM pw_userapp WHERE uid=" . pwEscape($uid) . " AND appid=" . pwEscape($appid));
     if ($rt['allowfeed']) {
         $descrip = Char_cv($descrip);
         $this->db->update("INSERT INTO pw_feed SET " . pwSqlSingle(array('uid' => $uid, 'type' => 'app', 'descrip' => $descrip, 'timestamp' => $timestamp), false));
         return new ApiResponse(true);
     }
     return new ApiResponse(false);
 }
开发者ID:adi00,项目名称:wumaproject,代码行数:12,代码来源:class_Feed.php

示例9: setCustomdata

 function setCustomdata($customdata)
 {
     global $db_union;
     if (!is_array($db_union)) {
         $db_union = explode("\t", stripslashes($db_union));
     }
     $custominfo = unserialize($db_union[7]);
     if ($custominfo && $customdata) {
         foreach ($customdata as $key => $val) {
             $key = Char_cv($key);
             $customdata[stripslashes($key)] = stripslashes($val);
         }
         $this->memberinfo['customdata'] = serialize($customdata);
     }
 }
开发者ID:adi00,项目名称:wumaproject,代码行数:15,代码来源:register.class.php

示例10: _setData

 function _setData()
 {
     $goodsname = Char_cv(GetGP('goodsname'));
     $price = Char_cv(GetGP('price'));
     $costprice = Char_cv(GetGP('costprice'));
     $locus = Char_cv(GetGP('locus'));
     $mailfee = Char_cv(GetGP('mailfee'));
     $expressfee = Char_cv(GetGP('expressfee'));
     $emsfee = Char_cv(GetGP('emsfee'));
     $degree = intval(GetGP('degree'));
     $ptype = intval(GetGP('ptype'));
     $goodsnum = intval(GetGP('goodsnum'));
     $paymethod = Char_cv(GetGP('paymethod'), 1);
     $transport = intval(GetGP('transport'));
     !$goodsname && ($goodsname = Char_cv($_POST['atc_title']));
     if (!is_numeric($costprice) || $costprice <= 0) {
         Showmsg('goods_setprice');
     }
     $goodsnum < 1 && Showmsg('goods_num_error');
     $paymethod && ($paymethod = array_sum($paymethod));
     $paymethod < 1 && Showmsg('goods_pay_error');
     !is_numeric($price) && ($price = 0);
     if ($transport) {
         !is_numeric($mailfee) && ($mailfee = 0);
         !is_numeric($expressfee) && ($expressfee = 0);
         !is_numeric($emsfee) && ($emsfee = 0);
         if (!$mailfee && !$expressfee && !$emsfee) {
             Showmsg('goods_logistics');
         }
     } else {
         $mailfee = $expressfee = $emsfee = 0;
     }
     $goodsicon = '';
     $this->data['name'] = $goodsname;
     $this->data['price'] = $price;
     $this->data['costprice'] = $costprice;
     $this->data['locus'] = $locus;
     $this->data['mailfee'] = $mailfee;
     $this->data['expressfee'] = $expressfee;
     $this->data['emsfee'] = $emsfee;
     $this->data['degree'] = $degree;
     $this->data['type'] = $ptype;
     $this->data['num'] = $goodsnum;
     $this->data['paymethod'] = $paymethod;
     $this->data['transport'] = $transport;
 }
开发者ID:adi00,项目名称:wumaproject,代码行数:46,代码来源:post_4.class.php

示例11: setData

 function setData()
 {
     $bonus = Char_cv(GetGP('bonus', 'P'), true);
     $ctype = Char_cv(GetGP('ctype', 'P'));
     $bonus['best'] < $this->b_val && Showmsg('credit_limit');
     $bonus['active'] < $this->a_val && Showmsg('credit_limit');
     reset($this->allowcredit);
     if (!$ctype['best']) {
         $ctype['best'] = current($this->allowcredit);
     }
     if (!$ctype['active']) {
         $ctype['active'] = current($this->allowcredit);
     }
     if (!in_array($ctype['best'], $this->allowcredit) || !in_array($ctype['active'], $this->allowcredit)) {
         Showmsg('reward_credit_error');
     }
     $this->data['cbtype'] = $ctype['best'];
     $this->data['catype'] = $ctype['active'];
     $this->data['cbval'] = $bonus['best'];
     $this->data['caval'] = $bonus['active'];
 }
开发者ID:adi00,项目名称:wumaproject,代码行数:21,代码来源:postreward.class.php

示例12: ModeList

function ModeList()
{
    $modes = array();
    if ($fp = opendir(R_P . 'mode')) {
        while ($modedir = readdir($fp)) {
            if (strpos($modedir, '.') === false) {
                $infodb = array();
                if (function_exists('file_get_contents')) {
                    $filedata = @file_get_contents(R_P . "mode/{$modedir}/info.xml");
                } else {
                    $filedata = readover(R_P . "mode/{$modedir}/info.xml");
                }
                if (preg_match('/\\<modename\\>(.+?)\\<\\/modename\\>\\s+\\<descrip\\>(.+?)\\<\\/descrip\\>/is', $filedata, $infodb)) {
                    $infodb[1] && ($modename = Char_cv(str_replace(array("\n"), '', $infodb[1])));
                }
                $modes[$modedir] = array('m_name' => $modename, 'ifopen' => 1, 'title' => $modename);
            }
        }
        closedir($fp);
    }
    return $modes;
}
开发者ID:adi00,项目名称:wumaproject,代码行数:22,代码来源:modeset.php

示例13: _setData

 function _setData()
 {
     $this->data['subject'] = Char_cv(GetGP('act_subject', 'P'));
     $this->data['location'] = Char_cv(GetGP('act_location', 'P'));
     $this->data['sexneed'] = intval(GetGP('act_sex'));
     $act_starttime = Char_cv(GetGP('act_starttime'));
     $act_deadline = Char_cv(GetGP('act_deadline'));
     $act_endtime = Char_cv(GetGP('act_endtime'));
     $act_num = intval(GetGP('act_num'));
     $act_costs = intval(GetGP('act_costs'));
     !($this->data['subject'] && $act_starttime && $act_deadline) && Showmsg('active_data_empty');
     $act_starttime = PwStrtoTime($act_starttime);
     $act_endtime = PwStrtoTime($act_endtime);
     $act_deadline = PwStrtoTime($act_deadline);
     $act_num < 1 && ($act_num = 0);
     $act_costs < 1 && ($act_costs = 0);
     $this->data['starttime'] = $act_starttime;
     $this->data['deadline'] = $act_deadline;
     $this->data['endtime'] = $act_endtime;
     $this->data['num'] = $act_num;
     $this->data['costs'] = $act_costs;
 }
开发者ID:adi00,项目名称:wumaproject,代码行数:22,代码来源:post_2.class.php

示例14: _setData

 function _setData()
 {
     global $timestamp;
     $endtime = Char_cv(GetGP('endtime'));
     $obtitle = Char_cv(GetGP('obtitle'));
     $retitle = Char_cv(GetGP('retitle'));
     $umpire = Char_cv(GetGP('umpire'));
     $endtime = PwStrtoTime($endtime);
     $endtime < $timestamp && Showmsg('debate_time');
     if (empty($obtitle) || empty($retitle)) {
         Showmsg('debate_notitle');
     } elseif (strlen($obtitle) > 255 || strlen($retitle) > 255) {
         Showmsg('debate_titlelen');
     }
     if ($umpire) {
         $umpireuid = $this->db->get_value("SELECT uid FROM pw_members WHERE username=" . pwEscape($umpire));
         empty($umpireuid) && Showmsg('debate_noumpire');
     }
     $this->data['endtime'] = $endtime;
     $this->data['obtitle'] = $obtitle;
     $this->data['retitle'] = $retitle;
     $this->data['umpire'] = $umpire;
     $this->data['postdate'] = $timestamp;
 }
开发者ID:adi00,项目名称:wumaproject,代码行数:24,代码来源:post_5.class.php

示例15: EncodeUrl

         !$modelid && ($topiccatestyle = 'style="display:none"');
         !$pcid && ($postcatestyle = 'style="display:none"');
         //团购活动
         @(include_once D_P . 'data/bbscache/postcate_config.php');
     }
     $ajaxurl = EncodeUrl($basename);
     include PrintEot('setforum');
     exit;
 } elseif ($_POST['step'] == 2) {
     $forum = $db->get_one("SELECT type,fup,forumadmin,logo FROM pw_forums WHERE fid=" . pwEscape($fid));
     InitGP(array('name', 'descrip', 'metadescrip'), 'P', 0);
     InitGP(array('vieworder', 'dirname', 'style', 'across', 'keywords'), 'P');
     $name = str_replace('<iframe', '&lt;iframe', $name);
     $descrip = str_replace('<iframe', '&lt;iframe', $descrip);
     $metadescrip = str_replace('<iframe', '&lt;iframe', $metadescrip);
     $keywords = Char_cv($keywords);
     strlen($descrip) > 250 && adminmsg('descrip_long');
     strlen($metadescrip) > 250 && adminmsg('descrip_long');
     if ($forum['type'] == 'category') {
         $db->update("UPDATE pw_forums SET " . pwSqlSingle(array('name' => $name, 'vieworder' => $vieworder, 'dirname' => $dirname, 'style' => $style, 'across' => $across, 'cms' => $cms)) . " WHERE fid=" . pwEscape($fid));
     } else {
         InitGP(array('forumsetdb', 'uploadset', 'rewarddb', 'cfup', 'ffup', 'showsub', 'ifhide', 'viewsub', 'allowhide', 'allowsell', 'copyctrl', 'f_check', 'password', 'allowvisit', 'allowread', 'allowpost', 'allowrp', 'allowupload', 'allowdownload', 'otherfid', 'otherforum', 'allowtime', 'allowtype', 'recycle', 'forumsell', 'sdate', 'cprice', 'rprice', 'logotype', 'logo_upload', 'logo_url', 'ifdellogo', 't_view_db', 'new_t_view_db', 't_logo_db', 'new_t_logo_db', 'new_t_sub_logo_db', 'new_t_sub_view_db', 't_type', 'modelid', 'pcid'), 'P');
         InitGP(array('t_db', 'new_t_db', 'new_t_sub_db', 'f_type'), 'P', 0);
         InitGP(array('ifcms'));
         //主题分类
         //更新原有的分类
         foreach ($t_db as $key => $value) {
             $db->update("UPDATE pw_topictype SET " . pwSqlSingle(array('name' => $value, 'vieworder' => $t_view_db[$key], 'logo' => $t_logo_db[$key])) . " WHERE id=" . pwEscape($key));
         }
         //增加新分类
         foreach ($new_t_db as $key => $value) {
开发者ID:adi00,项目名称:wumaproject,代码行数:31,代码来源:setforum.php


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