php function集合
/*更新商品的某个字段*/ function update_goods($goods_id, $field, $value) {if ($goods_id){/* 清除缓存 */clear_cache_files();$sql = "UPDATE " . $GLOBALS['ecs']->table('goods') ." SET $field = '$value' , last_update = '". gmtime() ."' " ."WHERE goods_id " . db_create_in($goods_id);return $GLOBALS['db']->query($sql);}else{return false;} } function message($msg, $url = NULL, $type = 'succeed', $waitSecond = 2) {if ($url == NULL)$url = 'javascript:history.back();';if ($type == 'error') {$title = '错误信息';} else {$title = '提示信息';}$data ['title'] = $title;$data ['message'] = $msg;$data ['type'] = $type;$data ['url'] = $url;$data ['second'] = $waitSecond;$this->assign('data', $data);$this->display('message');exit();}// 弹出信息 function alert($msg, $url = NULL, $parent = false) {header("Content-type: text/html; charset=utf-8");$alert_msg = "alert('$msg');";if (empty($url)) {$gourl = 'history.go(-1);';} else {$gourl = ($parent ? 'parent' : 'window') . ".location.href = '{$url}'";}echo "<script>$alert_msg $gourl</script>";exit();}
转载于:https://www.cnblogs.com/wesky/p/5887961.html
php function集合相关推荐
- 集合php,php function集合
/*更新商品的某个字段*/ function update_goods($goods_id, $field, $value) { if ($goods_id) { /* 清除缓存 */ clear_c ...
- ASP编程常用的函数function集合
<% '************************************* '防止外部提交 '****************************** ...
- Revising Aggregations - The Sum Function(集合函数-sum)
city表包含字段ID, NAME, COUNTRYCODE, DISTRICT,POPULATION 求district为California的人口总数 select sum(population) ...
- Revising Aggregations - The Count Function(集合函数-count)
city表包含字段ID, NAME, COUNTRYCODE, DISTRICT,POPULATION 问人口数大于10万的城市数 select count(1) from city where po ...
- 小波变换和motion信号处理(二)【转载】
这是<小波变换和motion信号处理>系列的第二篇,深入小波.第一篇我进行了基础知识的铺垫,第三篇主要讲解应用. 在上一篇中讲到,每个小波变换都会有一个mother wavelet,我们称 ...
- 二维小波变换_小波变换完美通俗讲解系列之 (一)
声明:该篇文章转自csdn,原始博主已经找不到了,在这里给出转载博主地址,如有侵权,请私信我删除. https://blog.csdn.net/liusandian/article/details/5 ...
- 小波变换完美通俗讲解系列之 (一)
申明:小波变换 完美通俗解读,是<小波变换和motion信号处理>系列中的第一篇. 原始出处为windstorm的网站http://www.kunli.info/,并非本站原创,但这位大 ...
- Quantal Response Equilibrium调研
Quantal Response Equilibrium Notes of QRE Palgrave 历史 灵感:Harsanyi (1973) and McFadden (1976),不完全信息博弈 ...
- 小波变换(wavelet transform)的通俗解释(一)
小波变换 小波,一个神奇的波,可长可短可胖可瘦(伸缩平移),当去学习小波的时候,第一个首先要做的就是回顾傅立叶变换(又回来了,唉),因为他们都是频率变换的方法,而傅立叶变换是最入门的,也是最先了解的, ...
最新文章
- 在Linux上安装Memcached服务
- 对象类什么是面向对象(1)
- MFC CString转换为字符数组
- 《MySQL——group by使用tips》
- 刷新认知!基因表达,男女有别|Science、Cell等发布15篇人类遗传调控新成果
- 金融工程与计算机联系紧密吗,美国留学金融工程专业院校有什么推荐的呢?
- LeetCode:Path Sum
- 网络交换机怎么连接硬盘录像机、网络交换机怎么连接摄像头
- 教你用VC6写热血江湖小外挂
- spring boot启动报错:Reason: Canonical names should be kebab-case (‘-‘ separated), lowercase
- python教学反思_Python语言教学反思
- Disconnected:No supported authentication methods available
- 广西艺术学院2012年本科招生专业考试通知
- 八条佛曰 66句震撼人心的禅语
- 托福高频真词List17 // 附托福TPO阅读真题
- 超实用后台UI模板有这些就够了!(三)
- TiDB上百T数据拆分实践
- 选择java版本_新手上路之如何选择Java版本
- 配置Apache服务
- nand flash外部引脚相关描述