初次接触discuznt的模板编码

声明一个变量:<%set (int){lastforumlayer} = -1%>

C#段:<%csharp%>

/*
聚合首面方法说明

*/
<%/csharp%>

应用方法内的变量:forumagg

<%set {topiclist} = forumagg.GetForumTopicList(10, 0, 21, TopicTimeType.Week, TopicOrderType.Replies, false, false)%>

循环
<%loop _ceshi topiclist%>
<li> <a href="{forumurl}{aspxrewriteurl}" style="{_ceshi[highlight]}" target="_blank"> <%getsubstring({_ceshi[title]},50,"...")%> </a> </li>
<%/loop%>

字符串改int:{strtoint({string})}

posted @ 2010-12-21 17:02  唔愛吃蘋果  阅读(242)  评论(0编辑  收藏  举报