摘要: https://c.runoob.com/codedemo/3852 阅读全文
posted @ 2018-04-04 17:29 xc_flying 阅读(193) 评论(0) 推荐(0) 编辑
摘要: 以上为自定义添加验证规则。 以上为表单提交,验证方法。 以上为生成动态表单,以及为动态表单元素添加验证规则。 阅读全文
posted @ 2018-04-04 16:17 xc_flying 阅读(1589) 评论(0) 推荐(0) 编辑
摘要: addslashes函数:数据库安全考虑 public function batchAdd($ids,$title,$content,$noticeType) { $sql = ""; $i = 0; foreach ($ids as $key=> $val) { if ($i == 0) { $s 阅读全文
posted @ 2018-04-02 17:27 xc_flying 阅读(123) 评论(0) 推荐(0) 编辑
摘要: $func = function($value) { return array(array('title'=>'','css'=>0,'content'=>$value,'image'=>[])); }; $trip=array_map($func, $newc... 阅读全文
posted @ 2018-03-22 15:47 xc_flying 阅读(245) 评论(0) 推荐(0) 编辑
摘要: //生成数据输出Excel,输出PDF文件同理可推。 阅读全文
posted @ 2018-03-21 11:00 xc_flying 阅读(548) 评论(0) 推荐(0) 编辑
摘要: PHP 中: header('Content-Type: text/html; charset=utf-8'); html中: <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 阅读全文
posted @ 2018-03-01 10:46 xc_flying 阅读(165) 评论(0) 推荐(0) 编辑
摘要: 漫道、闪通、容能 阅读全文
posted @ 2018-02-28 11:41 xc_flying 阅读(254) 评论(0) 推荐(0) 编辑
摘要: 虽然说ajax用来执行异步请求的比较多,但有时还是存在需要同步执行的情况的。 比如:我需要通过ajax取执行请求以返回一个值,这个值在ajax后面是需要使用到的,这时就不能用异步请求了。这时候就需要使用到async这个属性了。 async:true,(默认),异步方式,$.Ajax执行后,会继续执行 阅读全文
posted @ 2018-02-24 16:43 xc_flying 阅读(1229) 评论(0) 推荐(0) 编辑
摘要: mysql使in、find_in_set按顺序查出来 select * from table_name where id in ()或者select * from table_name where find_in_set()的时候,MySQL会自动按主键自增排序,要是按给定的顺序来取,如何实现呢? 阅读全文
posted @ 2018-02-08 11:11 xc_flying 阅读(453) 评论(0) 推荐(0) 编辑
摘要: $where1=array( 'b'=>$keywords, 'c'=>$keywords, '_logic'=>'and' ); $where=array( 'a'=>$keywords, '_complex'=>$where1, '_logic'=>'or' ); M('X')->where($where)->select(); 阅读全文
posted @ 2018-01-26 14:01 xc_flying 阅读(147) 评论(0) 推荐(0) 编辑