{pc:content action="lists" catid="$catid" where="typeid='$t'" order="id DESC" num="30"}
如上代碼,模板解析時,總是把where="typeid='$t'"中typeid='$t' 解析成字符串,不會解析$t變量
解決方法:
{php $where = "typeid=$t"}
{pc:content action="lists" catid="$catid" where="$where" order="id DESC" num="30"}
用字符串的方式傳遞where條件