随笔分类 -  phalApi

phalApi接口框架
摘要:http://blog.csdn.net/u011142688/article/details/51821412 阅读全文
posted @ 2017-09-29 08:35 pengcx 阅读(273) 评论(0) 推荐(0)
摘要:// WHERE name = 'dogstar' AND age = 18 $user->where(array('name' => 'dogstar', 'age' => 18)) // WHERE name = 'dogstar' OR age = 18 $user->or('name', ' 阅读全文
posted @ 2017-05-22 08:49 pengcx 阅读(2873) 评论(0) 推荐(0)
摘要:$sql = 'select * from example AS ep LEFT JOIN user AS u ON ep.ui d = u.id where ep.touid = :userId ORDER BY dateline desc LIMIT :start,:num'; $params 阅读全文
posted @ 2017-02-22 19:56 pengcx 阅读(1477) 评论(0) 推荐(0)
摘要:1、'email' => array( 'name' => 'email', 'require' => true, 'min' => '1', 'regex' => "/^([0-9A-Za-z\\-_\\.]+)@([0-9a-z]+\\.[a-z]{2,3}(\\.[a-z]{2})?)$/i" 阅读全文
posted @ 2017-02-17 08:40 pengcx 阅读(526) 评论(0) 推荐(0)
摘要:http://demo.phalapi.net/?service=User.getBaseInfo&user_id=1&__sql__=1 阅读全文
posted @ 2017-02-16 10:54 pengcx 阅读(2286) 评论(0) 推荐(0)
摘要:在很多时候,我们会遇到数据库表里面的某个值需要+1操作,我们不能简单地在update的时候写入array('key' => 'key+1'),因为在解析sql的时候,key+1 会带上引号作为一个字符串被处理,所以,这样的操作并没有达到我们想要的效果,当然,这是有解决方法的。具体操作如下: 阅读全文
posted @ 2017-02-13 15:13 pengcx 阅读(3411) 评论(0) 推荐(0)