我的笔记
{if value1="{fzw:url:laiyuanbianhao/}" value2="" bi="=="} 笔记({fzw:sql="select count(id) as bijishu from sl_biji where yonghuming='{fzw:cookie:name="user_name"/}'" id="p1"}{fzw:p1:bijishu/}{/fzw:sql}) 提问({fzw:sql="select count(id) as tiwenshu from sl_wenda where leixing='提问' and fasongren='{fzw:cookie:name="user_name"/}'" id="p1"}{fzw:p1:tiwenshu/}{/fzw:sql}) 评论({fzw:sql="select count(id) as pinglunshu from sl_pinglun where leixing='视频' and yonghuming='{fzw:cookie:name="user_name"}'" id="p1"}{fzw:p1:pinglunshu/}{/fzw:sql}) {else} 笔记({fzw:sql="select count(id) as bijishu from sl_biji where laiyuanbianhao={fzw:url:laiyuanbianhao/}" id="p1"}{fzw:p1:bijishu/}{/fzw:sql}) 提问({fzw:sql="select count(id) as tiwenshu from sl_wenda where laiyuanbianhao={fzw:url:laiyuanbianhao/} and leixing='提问' and fasongren='{fzw:cookie:name="user_name"/}'" id="p1"}{fzw:p1:tiwenshu/}{/fzw:sql}) 评论({fzw:sql="select count(id) as pinglunshu from sl_pinglun where laiyuanbianhao={fzw:url:laiyuanbianhao/} and leixing='视频' and yonghuming='{fzw:cookie:name="user_name"}'" id="p1"}{fzw:p1:pinglunshu/}{/fzw:sql}) {/if}
{fzw:sql="select *,(select top 1 biaoti from sl_jie as j,sl_history as h where j.laiyuanbianhao in (select kechengjie from sl_kecheng where id={fzw:p1:laiyuanbianhao/}) and j.id=h.laiyuanbianhao order by h.dtime desc) as jiebiaoti,(select top 1 j.id from sl_jie as j,sl_history as h where j.laiyuanbianhao in (select kechengjie from sl_kecheng where id={fzw:p1:laiyuanbianhao/}) and j.id=h.laiyuanbianhao order by h.dtime desc) as jieid from sl_kecheng as kc,sl_user as u where kc.id={fzw:p1:laiyuanbianhao/} and kc.yonghuming=u.yonghuming" id="p2"}
{/fzw:sql}
{/fzw:search}
{if value1="{fzw:p2:nicheng/}" value2="" bi="=="}{fzw:p2:yonghuming/}{else}{fzw:p2:nicheng/}{/if}
{fzw:p1:neirong/}
时间:{fzw:p1:dtime string="shijian"/}
{fzw:search:page id="p1" size="5"/}