1、完善前端模板功能

2、完善伪静态规则设置
This commit is contained in:
2020-04-17 16:46:32 +08:00
parent ce9b63dda1
commit 83ce571a3f
6 changed files with 135 additions and 57 deletions

View File

@@ -36,9 +36,9 @@ class Sent extends \think\template\TagLib {
public function tagdoc($tag, $content){
$model = !empty($tag['model']) ? $tag['model']:'';
$cid = (!empty($tag['cid']) && is_integer($tag['limit'])) ? $tag['cid']:'0';
$cid = isset($tag['cid']) ? (int) $tag['cid'] : 20;
$field = empty($tag['field']) ? '*' : $tag['field'];
$limit = (!empty($tag['limit']) && is_integer($tag['limit'])) ? $tag['limit'] : 20;
$limit = isset($tag['limit']) ? (int) $tag['limit'] : 20;
$order = empty($tag['order']) ? 'id desc' : $tag['order'];
$name = isset($tag['name']) ? $tag['name'] : 'item';