ThinkPHP5中where查询条件使用数组时设置or或者and的写法:
$where['status'] = array(['=',1],['=',3],'or');
上面代码等同于:
where status = 1 or status = 3;
零五科技,分享IT知识,国内顶级IT知识门户网站。
Copyright (C) www.02405.com, All Rights Reserved.
零五科技 版权所有 辽ICP备13002105号-1