标题{$rs.title}
内容页网址{$rs.url}
封面图(缩略图){$rs.picurl}
时间{$rs.time}
序号,比如1 2 3 4 5 6 你可以把他放在class里边实现一些不一样的特效 比如class="list_{$i}"
{$i}
内容介绍,代表取100个字节,一个汉字相当于3个字节{$rs.content|get_word=100}
分类名称{$rs.sort_name}
栏目网址{$rs.sort_url}
模型名称{$rs.mid_name}
发布者 主页{$rs.user_url}
发布者 头像{$rs.user_icon}
发布者 帐号{$rs.username}
内容页要使用作者的帐号或头像用下面的代码{$info.uid|get_user_name}
{$info.uid|get_user_icon}
{:get_url('user',$info.uid)}
某些列表数据,如果{$rs.username} {$rs.user_icon}
不存在的话,请使用下面的{$rs.uid|get_user_name}
{$rs.uid|get_user_icon}
{:get_url('user',$rs.uid)}
时间自定义格式, "Y-m-d H:i:s" 为日期格式{$rs.create_time|format_time="Y-m-d H:i:s"}
当前URL{:get_url('location')}
当前URL二维码{:urls('index/qrcode/index')}?url={:urlencode(get_url('location'))}
网站名称{$webdb.webname}
网址{$webdb[www_url]}
标题字数限制,代表取20个字节,一个汉字相当于3个字节{$rs.title|get_word=20}
内容页 标题{$info.title}
内容页 内容{$info.content}
内容页 浏览量{$info.view}
内容页 发布时间{:date("Y-m-d H:i:s",$info.create_time)}
内容页 评论数{:fun('Comment@total',$id)}
内容页 上一页{:fun('content@prev',$info,20)}
内容页 下一页{:fun('content@next',$info,20)}
其中20代表取标题多少个字, 为了排版需要,你不想要标题的话,可以换成字符,比如{:fun('content@prev',$info,'上一页')}
CMS文章 统计数{:query('cms_content',['count'=>'id'])}
商城内容 统计数{:query('shop_content',['count'=>'id'])}
评论内容 统计数{:query('comment_content',['count'=>'id'])}
分类系统 统计数{:query('fenlei_content',['count'=>'id'])}
圈子系统 统计数{:query('qun_content',['count'=>'id'])}
论坛系统 统计数{:query('bbs_content',['count'=>'id'])}
昵称 账户{:get_user($info['uid'],'username')}
一级导航图标{$rs.style}
二级导航图标{$vs.style}
数据表名:query('module')
列表页 上下页{$pages}
会员中心 UID{$userdb.uid}
会员中心 账号{$userdb.username}
会员中心 昵称{$userdb.nickname}
会员中心 所属用户组{$userdb.groupid|getGroupByid}
会员中心 所属用户组ID{$userdb.groupid}
会员中心 余额{$userdb.rmb}
会员中心 头像{$userdb.icon|tempdir}
会员中心 积分{$userdb.money}
会员中心 注册时间{$user.regdate|format_time}
会员中心 上次访问时间{$user.lastvist|date="Y-m-d H:i",###}
会员中心 性别{switch $userdb.sex}{case 1}男{/case}{case 2}女{/case}{default /}保密{/switch}
会员中心 是否认证{notempty name="userdb.yz"}已认证{else /}未认证{/notempty}
会员中心 是否登陆{notempty name="$userdb"}已登录{else /}没登陆{/notempty}
会员中心调用会员的相关数据,使用动态变量,直接用where语句可以直接加变量(此用法在圈子与黄页及微动态将会大量用到,方便实现数据汇总)where="uid=$uid&fid=$info.fid"
内容页 当前栏目{:get_sort($info.fid)}
栏目字段,在栏目循环中一般$fid
以$key
出现{:get_sort($fid,'logo')}
{:get_sort(栏目ID,'字段名')}
内容页 当前栏目URL{:urls('index','fid='.$fid)}
变量怎么用啊
总结得很好
不错不错,收藏了,这样确实好,搞个模板到处去找变量,累得慌。
请问目前购物车数量可以在全站调用吗