|
$postdata是一个数组,数据结构如下
PHP复制代码 array
'olddevice' => string '555' (length =3)
'oldcarrier' => string 'd' (length =1)
'cmd' => string 'ms_editcheck' (length =12)
'model' => string '555' (length =3)
'device' => string '555' (length =3)
'series' => string 'd' (length =1)
'carrier' => string 'd' (length =1)
'support_kbn' => string '2' (length =1)
'support_app' => string '2' (length =1)
'pid8' => string 'on' (length =2)
'pid9' => string 'on' (length =2) 复制代码
现在要使用smarty,下面是我的写法,但是不行
PHP复制代码 {{section name=co2 loop=$gamedata}}
{{if $postdata.pid|cat:$gamedata[co2].pid eq "on"}}
aaa
{{else}}
{{/section}} 复制代码
还有
返回的是一些数字,比如8,9...
该如何将postdata中的pid8或pid9中的字段取出来?
[ 本帖最后由 sam 于 2008-12-28 08:53 编辑 ] |
|