这里会显示出您选择的修订版和当前版本之间的差别。
zblogphp:development:functions:getlist [2020/12/31 14:39] zx.asd |
zblogphp:development:functions:getlist [2021/01/16 14:45] (当前版本) |
||
---|---|---|---|
行 16: | 行 16: | ||
'tags' => 'abc', //(可省略) | 'tags' => 'abc', //(可省略) | ||
'search' => 's', //(可省略) | 'search' => 's', //(可省略) | ||
+ | //以下是原$option参数的key键 | ||
'post_type' => null, //指定查询Post表的类型 (可省略) | 'post_type' => null, //指定查询Post表的类型 (可省略) | ||
'post_status' => null, //指定查询Post表的状态 (可省略) | 'post_status' => null, //指定查询Post表的状态 (可省略) | ||
行 23: | 行 24: | ||
'is_related' => false, //指定查询相关文章 (可省略) | 'is_related' => false, //指定查询相关文章 (可省略) | ||
'order_by_metas' => false, //指定按Metas值排序输出结果 (可省略) | 'order_by_metas' => false, //指定按Metas值排序输出结果 (可省略) | ||
- | 'random' => 5 //指定抽取5篇Post表的记录 (可省略) | + | 'random' => 5, //指定抽取5篇Post表的记录 (可省略) |
+ | 'where_custom' => array(array('=', 'log_Template', '')), //自定义where | ||
+ | 'order_custom' => array('log_ViewNums' => 'DESC', 'log_CommNums' => 'ASC'), //自定义order | ||
) | ) | ||
</code> | </code> |