website.aspx
上传用户:wenllgg125
上传日期:2020-04-09
资源大小:7277k
文件大小:88k
- <%@ Page language="c#" AutoEventWireup="false" EnableViewState="false" Inherits="Discuz.Web.website" %>
- <%@ Import namespace="System.Data" %>
- <%@ Import namespace="Discuz.Common" %>
- <%@ Import namespace="Discuz.Forum" %>
- <%@ Import namespace="Discuz.Entity" %>
- <script runat="server">
- override protected void OnInit(EventArgs e)
- {
- /*
- This page was created by Discuz!NT Template Engine at 2010/2/8 15:43:55.
- 本页面代码由Discuz!NT模板引擎生成于 2010/2/8 15:43:55.
- */
- base.OnInit(e);
- templateBuilder.Capacity = 220000;
- /*
- 聚合首面方法说明
-
- ///////////////////////////////////////////////////////////////////////////////////////////////
-
- 方法名称: GetForumTopicList(count, views, forumid, timetype, ordertype, isdigest, onlyimg)
- 方法说明: 返回指定条件的主题列表信息
- 参数说明:
- count : 返回的主题数
- views : 浏览量 [返回等于或大于当前浏览量的主题]
- forumid : 版块ID [默认值 0 为所有版块]
- timetype : 指定时间段内的主题 [ TopicTimeType.Day(一天内) , TopicTimeType.Week(一周内), TopicTimeType.Month(一个月内), TopicTimeType.SixMonth(六个月内), TopicTimeType.Year(一年内), TopicTimeType.All(默认 从1754-1-1至今的所有主题)
- ordertype : 排序字段(降序) [TopicOrderType.ID(默认 主题ID) , TopicOrderType.Views(浏览量), TopicOrderType.LastPost(最后回复), TopicOrderType.PostDateTime(按最新主题查), TopicOrderType.Digest(按精华主题查), TopicOrderType.Replies(按回复数)]
- isdigest : 是否精化 [true(仅返回精华主题) false(不加限制)]
- onlyimg : 是否包含附件 [true(仅返回包括图片附件的主题) false(不加限制)]
-
- //////////////////////////////////////////////////////////////////////////////////////////////
-
- 方法名称: GetHotForumList(count)
- 方法说明: 返回指定数量的热门版块列表
- 参数说明:
- count : 返回的版块数
-
- //////////////////////////////////////////////////////////////////////////////////////////////
-
- 方法名称: GetForumList(forumid)
- 方法说明: 返回指定版块下的所有子段块列表
- 参数说明:
- forumid : 指定的版块id
-
- //////////////////////////////////////////////////////////////////////////////////////////////
-
- 方法名称: GetLastPostList(forumid, count)
- 方法说明: 返回指定版块下的最新回帖列表
- 参数说明:
- forumid : 指定的版块id
- count : 返回的回帖数
-
- //////////////////////////////////////////////////////////////////////////////////////////////
-
- 方法名称: GetAlbumList(photoconfig.Focusalbumshowtype, count, days)
- 方法说明: 返回指定条件的相册列表
- 参数说明:
- photoconfig.Focusalbumshowtype : 排序字段(降序) [1(浏览量), 2(照片数), 3(创建时间)] 注:管理后台聚合设置项
- count : 返回的相册数
- days :有效天数 [指定天数内的相册]
-
- //////////////////////////////////////////////////////////////////////////////////////////////
-
- 方法名称: GetWeekHotPhotoList(photoconfig.Weekhot)
- 方法说明: 返回指定数量的热门图片
- 参数说明:
- photoconfig.Weekhot : 返回的热图数量 注:管理后台聚合设置项
-
- //////////////////////////////////////////////////////////////////////////////////////////////
-
- 方法名称: GetSpaceTopComments(count)
- 方法说明: 返回指定数量的空间最新评论
- 参数说明:
- count : 返回的评论数
-
- //////////////////////////////////////////////////////////////////////////////////////////////
-
- 方法名称: GetRecentUpdateSpaceList(count)
- 方法说明: 返回指定数量的最新更新空间列表
- 参数说明:
- count : 返回的空间信息数
-
-
- //////////////////////////////////////////////////////////////////////////////////////////////
-
- 方法名称: GetGoodsList(condition, orderby, categoryid, count)
- 方法说明: 返回指定数量的最新更新空间列表
- 参数说明:
- condition : 条件 [recommend(仅返回推荐商品, 商城模式下可用) , quality_new(仅返回全新(状态)商品), quality_old(仅返回二手(状态)商品)]
- orderby: 排序字段(降序) [viewcount(按浏览量排序), hotgoods(按商品交易量排序), newgoods(按发布商品先后顺序排序) ]
- categoryid : 商品所属分类id [默认值 0 为不加限制]
- count : 返回的商品数
-
-
- //////////////////////////////////////////////////////////////////////////////////////////////
-
- 方法名称: GetUserList(count, orderby)
- 方法说明: 返回指定数量及排序方式的用户列表
- 参数说明:
- count : 返回的用户数
- orderby: 排序字段(降序) [credits(用户积分), posts(用户发帖数), lastactivity(最后活动时间), joindate(注册时间), oltime(在线时间)]
- */
-
- templateBuilder.Append("<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">rn");
- templateBuilder.Append("<html xmlns="http://www.w3.org/1999/xhtml">rn");
- templateBuilder.Append("<head>rn");
- templateBuilder.Append("<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />rn");
- templateBuilder.Append(meta.ToString());
- templateBuilder.Append("rn");
- templateBuilder.Append("<title>");
- templateBuilder.Append(pagetitle.ToString());
- templateBuilder.Append(" ");
- templateBuilder.Append(config.Seotitle.ToString().Trim());
- templateBuilder.Append(" - ");
- templateBuilder.Append(config.Webtitle.ToString().Trim());
- templateBuilder.Append(" - Powered by Discuz!NT</title>rn");
- templateBuilder.Append("<meta name="generator" content="Discuz!NT 3.1.0" />rn");
- templateBuilder.Append("<meta name="author" content="Discuz!NT Team and Comsenz UI Team" />rn");
- templateBuilder.Append("<meta name="copyright" content="2001-2010 Comsenz Inc." />rn");
- templateBuilder.Append("<meta http-equiv="x-ua-compatible" content="ie=7" />rn");
- templateBuilder.Append("<link rel="icon" href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("favicon.ico" type="image/x-icon" />rn");
- templateBuilder.Append("<link rel="shortcut icon" href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("favicon.ico" type="image/x-icon" />rn");
- templateBuilder.Append("<link rel="stylesheet" href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/float.css" type="text/css" media="all" />rn");
- templateBuilder.Append("<link rel="stylesheet" href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/website.css" type="text/css" media="all" />rn");
- templateBuilder.Append(link.ToString());
- templateBuilder.Append("rn");
- templateBuilder.Append("<script type="text/javascript" src="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("javascript/template_report.js"></");
- templateBuilder.Append("script>rn");
- templateBuilder.Append("<script type="text/javascript" src="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("javascript/template_utils.js"></");
- templateBuilder.Append("script>rn");
- templateBuilder.Append("<script type="text/javascript" src="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("javascript/template_website.js"></");
- templateBuilder.Append("script>rn");
- templateBuilder.Append("<script type="text/javascript" src="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("javascript/common.js"></");
- templateBuilder.Append("script>rn");
- templateBuilder.Append(script.ToString());
- templateBuilder.Append("rn");
- templateBuilder.Append("<script type="text/javascript">rn");
- templateBuilder.Append(" var aspxrewrite = ");
- templateBuilder.Append(config.Aspxrewrite.ToString().Trim());
- templateBuilder.Append(";rn");
- templateBuilder.Append(" var IMGDIR = '");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images'rn");
- templateBuilder.Append(" var allowfloatwin = ");
- templateBuilder.Append(config.Allowfloatwin.ToString().Trim());
- templateBuilder.Append("rn");
- templateBuilder.Append(" var rooturl="");
- templateBuilder.Append(rooturl.ToString());
- templateBuilder.Append("";rn");
- templateBuilder.Append("</");
- templateBuilder.Append("script>rn");
- templateBuilder.Append("</head>rn");
- templateBuilder.Append("<body onkeydown="if(event.keyCode==27) return false;">rn");
- templateBuilder.Append("<div id="append_parent"></div><div id="ajaxwaitid"></div>rn");
- templateBuilder.Append("<div id="header">rn");
- templateBuilder.Append(" <div class="wrap head s_clear">rn");
- templateBuilder.Append(" <h2><a title="");
- templateBuilder.Append(config.Seotitle.ToString().Trim());
- templateBuilder.Append("" href="/index.aspx"><img alt="");
- templateBuilder.Append(config.Webtitle.ToString().Trim());
- templateBuilder.Append("" src="templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/gather/sitelogo.gif"/></a></h2>rn");
- if (headerad!="")
- {
- templateBuilder.Append(" <div id="ad_headerbanner" style="display:none;">");
- templateBuilder.Append(headerad.ToString());
- templateBuilder.Append("</div>rn");
- } //end if
- templateBuilder.Append(" <div id="user_info" class="user_info">rn");
- if (userid==-1)
- {
- templateBuilder.Append(" <form id="loginform" name="loginform" method="post" action="");
- templateBuilder.Append(rooturl.ToString());
- templateBuilder.Append("login.aspx?referer=website.aspx">rn");
- templateBuilder.Append(" <dl class="login"> rn");
- templateBuilder.Append(" <dt>用户名</dt>rn");
- templateBuilder.Append(" <dd><input type="text" id="username" name="username" autocomplete="off" size="12" maxlength="20" value="" tabindex="1" class="txt"/></dd>rn");
- templateBuilder.Append(" <dt>密码</dt>rn");
- templateBuilder.Append(" <dd><input type="password" id="password3" name="password" size="12" class="txt" tabindex="1"/></dd>rn");
- templateBuilder.Append(" <dd class="btn"><input type="image" src="");
- templateBuilder.Append(forumpath.ToString());
- templateBuilder.Append("templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/gather/btn_login.gif" alt="登录" /></dd>rn");
- templateBuilder.Append(" <dd class="btn"><input type="image" src="");
- templateBuilder.Append(forumpath.ToString());
- templateBuilder.Append("templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/gather/btn_register.gif" alt="注册" onclick="window.location='");
- templateBuilder.Append(forumpath.ToString());
- templateBuilder.Append("register.aspx';return false" /></dd>rn");
- templateBuilder.Append(" </dl>rn");
- templateBuilder.Append(" <input type="checkbox" value="43200" tabindex="1" id="expires" name="expires" checked style="display:none"/>rn");
- templateBuilder.Append(" </form>rn");
- }
- else
- {
- templateBuilder.Append(" <dl class="user">rn");
- templateBuilder.Append(" <dt><a alt="用户名称" title="用户名称" target="_blank" href="usercp.aspx"><img src="");
- templateBuilder.Append(useravatar.ToString());
- templateBuilder.Append("" onerror="this.onerror=null;this.src='templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/noavatar_small.gif';" /></a></dt>rn");
- templateBuilder.Append(" <dd>rn");
- templateBuilder.Append(" <ul>rn");
- templateBuilder.Append(" <li><strong>欢迎");
- templateBuilder.Append(username.ToString());
- templateBuilder.Append("</strong>rn");
- templateBuilder.Append(" <a target="_blank" href="usercpinbox.aspx" title="");
- templateBuilder.Append(oluserinfo.Newpms.ToString().Trim());
- templateBuilder.Append("条新短消息">短消息rn");
- if (oluserinfo.Newpms>0)
- {
- templateBuilder.Append("(");
- templateBuilder.Append(oluserinfo.Newpms.ToString().Trim());
- templateBuilder.Append(")rn");
- } //end if
- templateBuilder.Append("</a>rn");
- templateBuilder.Append(" <span class="pipe">|</span>rn");
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(forumpath.ToString());
- templateBuilder.Append("usercpnotice.aspx?filter=all">通知rn");
- if (oluserinfo.Newnotices>0)
- {
- templateBuilder.Append("(");
- templateBuilder.Append(oluserinfo.Newnotices.ToString().Trim());
- templateBuilder.Append(")rn");
- } //end if
- templateBuilder.Append("</a>rn");
- templateBuilder.Append(" <span class="pipe">|</span>rn");
- if (useradminid==1)
- {
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(forumpath.ToString());
- templateBuilder.Append("admin/index.aspx" target="_blank">系统设置</a>rn");
- templateBuilder.Append(" <span class="pipe">|</span>rn");
- } //end if
- templateBuilder.Append(" <a href="logout.aspx?userkey=");
- templateBuilder.Append(userkey.ToString());
- templateBuilder.Append("">退出</a>rn");
- templateBuilder.Append(" </li>rn");
- templateBuilder.Append(" <li>rn");
- if (score[1].ToString().Trim()!="")
- {
- templateBuilder.Append("" + score[1].ToString().Trim() + ": ");
- templateBuilder.Append(score1.ToString());
- templateBuilder.Append("rn");
- } //end if
- if (score[2].ToString().Trim()!="")
- {
- templateBuilder.Append(", " + score[2].ToString().Trim() + ": ");
- templateBuilder.Append(score2.ToString());
- templateBuilder.Append("rn");
- } //end if
- if (score[3].ToString().Trim()!="")
- {
- templateBuilder.Append(", " + score[3].ToString().Trim() + ": ");
- templateBuilder.Append(score3.ToString());
- templateBuilder.Append("rn");
- } //end if
- templateBuilder.Append(" </li>rn");
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </dd>rn");
- templateBuilder.Append(" </dl>rn");
- } //end if
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div id="menu">rn");
- templateBuilder.Append(" <ul class="wrap s_clear">rn");
- templateBuilder.Append(" ");
- templateBuilder.Append(mainnavigation.ToString());
- templateBuilder.Append("rn");
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<div id="nav">rn");
- templateBuilder.Append(" <div class="wrap s_clear">rn");
- templateBuilder.Append(" <span class="right">rn");
- templateBuilder.Append(" <a href="showtopiclist.aspx?type=newtopic">查看新帖</a>rn");
- templateBuilder.Append(" <a href="showtopiclist.aspx?type=digest&forums=all">精华区</a>rn");
- templateBuilder.Append(" <a target="_blank" href="tools/rss.aspx"><img alt="rss" src="templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/icon_feed.gif"/></a>rn");
- templateBuilder.Append(" </span>rn");
- if (usergroupinfo.Allowsearch>0)
- {
- templateBuilder.Append(" <div id="search">rn");
- templateBuilder.Append(" <form method="post" action="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("search.aspx" target="_blank" onsubmit="bind_keyword(this);">rn");
- templateBuilder.Append(" <input type="hidden" name="poster" />rn");
- templateBuilder.Append(" <input type="hidden" name="keyword" />rn");
- templateBuilder.Append(" <input type="hidden" name="type" value="" />rn");
- templateBuilder.Append(" <input id="keywordtype" type="hidden" name="keywordtype" value="0" />rn");
- templateBuilder.Append(" <dl>rn");
- templateBuilder.Append(" <dt style="display:none;">快速搜索</dt>rn");
- templateBuilder.Append(" <dd><input name="keywordf" type="text" class="keywords" id="keywordf" onblur="if(this.value=='')this.value=defaultValue" onclick="if(this.value==this.defaultValue)this.value = ''" onkeydown="if(this.value==this.defaultValue)this.value = ''" value="输入搜索关键字"/><div class="select_chose" id="quicksearch" onclick="showMenu(this.id, false);" onmouseover="MouseCursor(this);">标题</div>rn");
- templateBuilder.Append(" </dd>rn");
- templateBuilder.Append(" <dd style="padding:1px 4px 4px;"><input type="submit" class="btnsearch" value="搜索" name="searchsubmit"/></dd>rn");
- templateBuilder.Append(" </dl>rn");
- templateBuilder.Append(" </form> rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <script type="text/javascript">rn");
- templateBuilder.Append(" function bind_keyword(form) {rn");
- templateBuilder.Append(" if (form.keywordtype.value == '9') {rn");
- templateBuilder.Append(" form.action = '");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("forumsearch.aspx?q=' + escape(form.keywordf.value);rn");
- templateBuilder.Append(" } else if (form.keywordtype.value == '8') {rn");
- templateBuilder.Append(" form.keyword.value = '';rn");
- templateBuilder.Append(" form.poster.value = form.keywordf.value;rn");
- templateBuilder.Append(" } else {rn");
- templateBuilder.Append(" form.poster.value = '';rn");
- templateBuilder.Append(" form.keyword.value = form.keywordf.value;rn");
- templateBuilder.Append(" if (form.keywordtype.value == '2')rn");
- templateBuilder.Append(" form.type.value = 'spacepost';rn");
- templateBuilder.Append(" if (form.keywordtype.value == '3')rn");
- templateBuilder.Append(" form.type.value = 'album';rn");
- templateBuilder.Append(" }rn");
- templateBuilder.Append(" }rn");
- templateBuilder.Append(" </");
- templateBuilder.Append("script>rn");
- } //end if
- templateBuilder.Append(" <a class="title" onmouseout="showMenu(this.id);" onmouseover="showMenu(this.id);" href="forumindex.aspx" id="forumlist">");
- templateBuilder.Append(config.Forumtitle.ToString().Trim());
- templateBuilder.Append("</a> » 首页rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<ul id="quicksearch_menu" class="popupmenu_popup" style="display:none;">rn");
- templateBuilder.Append(" <li onclick="$('keywordtype').value='0';$('quicksearch').innerHTML='标题';$('quicksearch_menu').style.display='none';" onmouseover="MouseCursor(this);">标题</li>rn");
- if (config.Enablespace==1)
- {
- templateBuilder.Append(" <li onclick="$('keywordtype').value='2';$('quicksearch').innerHTML='空间';$('quicksearch_menu').style.display='none';" onmouseover="MouseCursor(this);">空间</li>rn");
- } //end if
- if (config.Enablealbum==1)
- {
- templateBuilder.Append(" <li onclick="$('keywordtype').value='3';$('quicksearch').innerHTML='相册';$('quicksearch_menu').style.display='none';" onmouseover="MouseCursor(this);">相册</li>rn");
- } //end if
- templateBuilder.Append(" <li onclick="$('keywordtype').value='8';$('quicksearch').innerHTML='作者';$('quicksearch_menu').style.display='none';" onmouseover="MouseCursor(this);">作者</li>rn");
- templateBuilder.Append(" <li onclick="$('keywordtype').value='9';$('quicksearch').innerHTML='版块';$('quicksearch_menu').style.display='none';" onmouseover="MouseCursor(this);">版块</li>rn");
- templateBuilder.Append("</ul>rn");
- templateBuilder.Append("<div class="wrap s_clear contentbox">rn");
- if (page_err==0)
- {
- templateBuilder.Append("<div id="websiteheaderad" class="ad s_clear"></div>rn");
- templateBuilder.Append("<div id="forum_global" class="forum_global s_clear">rn");
- templateBuilder.Append(" <div class="forum_main">rn");
- templateBuilder.Append(" <div class="topic">rn");
- int toppost__loop__id=0;
- foreach(PostInfo toppost in postlist)
- {
- toppost__loop__id++;
- if (toppost__loop__id==3)
- {
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="topic_list">rn");
- templateBuilder.Append(" <ul> rn");
- } //end if
- if (toppost__loop__id==11)
- {
- templateBuilder.Append(" </ul><ul>rn");
- } //end if
- if (toppost__loop__id<=2)
- {
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(ShowTopicAspxRewrite(toppost.Tid,0).ToString().Trim());
- templateBuilder.Append("" target="_blank">rn");
- templateBuilder.Append(" <h2><a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(ShowTopicAspxRewrite(toppost.Tid,0).ToString().Trim());
- templateBuilder.Append("" target="_blank">");
- templateBuilder.Append(toppost.Title.ToString().Trim());
- templateBuilder.Append("</a></h2>rn");
- templateBuilder.Append(" <p><a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(ShowTopicAspxRewrite(toppost.Tid,0).ToString().Trim());
- templateBuilder.Append("" target="_blank">");
- templateBuilder.Append(toppost.Message.ToString().Trim());
- templateBuilder.Append("</a></p>rn");
- }
- else
- {
- templateBuilder.Append(" <li>rn");
- templateBuilder.Append(" <strong>rn");
- aspxrewriteurl = this.ShowForumAspxRewrite(toppost.Fid,0,toppost.ForumRewriteName);
-
- templateBuilder.Append(" [<a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">");
- templateBuilder.Append(toppost.Forumname.ToString().Trim());
- templateBuilder.Append("</a>]rn");
- templateBuilder.Append(" </strong>rn");
- aspxrewriteurl = this.ShowTopicAspxRewrite(toppost.Tid,0);
-
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank" title="");
- templateBuilder.Append(toppost.Title.ToString().Trim());
- templateBuilder.Append("">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(toppost.Title,43,"..."));
- templateBuilder.Append("</a>rn");
- templateBuilder.Append(" </li> rn");
- } //end if
- if (toppost__loop__id==18)
- {
- break;
- } //end if
- } //end loop
- if (postlist.Length>=11||postlist.Length>2&&postlist.Length<11)
- {
- templateBuilder.Append(" </ul>rn");
- } //end if
- templateBuilder.Append(" </div>rn");
- if (postlist.Length<3)
- {
- templateBuilder.Append(" <div class="topic_list">rn");
- templateBuilder.Append(" <ul> rn");
- topiclist = forumagg.GetForumTopicList(16, 0, 0, TopicTimeType.Year, topicordertype, false, false);
-
- int toptopicinfo__loop__id=0;
- foreach(DataRow toptopicinfo in topiclist.Rows)
- {
- toptopicinfo__loop__id++;
- if (toptopicinfo__loop__id==9)
- {
- templateBuilder.Append(" </ul><ul>rn");
- } //end if
- templateBuilder.Append(" <li>rn");
- templateBuilder.Append(" <strong>rn");
- aspxrewriteurl = this.ShowForumAspxRewrite(Utils.StrToInt(toptopicinfo["fid"].ToString().Trim(), 0),0,toptopicinfo["rewritename"].ToString().Trim());
-
- templateBuilder.Append(" [<a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">" + toptopicinfo["name"].ToString().Trim() + "</a>]rn");
- templateBuilder.Append(" </strong>rn");
- aspxrewriteurl = this.ShowTopicAspxRewrite(toptopicinfo["tid"].ToString().Trim(),0);
-
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank" title="" + toptopicinfo["title"].ToString().Trim() + "">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(toptopicinfo["title"].ToString().Trim(),43,"..."));
- templateBuilder.Append("</a>rn");
- templateBuilder.Append(" </li> rn");
- } //end loop
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- } //end if
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="forum_exta">rn");
- templateBuilder.Append(" <div class="flash s_clear">rn");
- if (rotatepicdata!=null && rotatepicdata!="")
- {
- templateBuilder.Append(" <div class="modulebox" style="padding:1px;">rn");
- templateBuilder.Append(" <script type='text/javascript'>rn");
- templateBuilder.Append(" var imgwidth = 320;rn");
- templateBuilder.Append(" var imgheight = 240;rn");
- templateBuilder.Append(" </");
- templateBuilder.Append("script> rn");
- templateBuilder.Append(" <!--图片轮换代码开始-->rn");
- templateBuilder.Append(" <script type="text/javascript" src="javascript/template_rotatepic.js"></");
- templateBuilder.Append("script>rn");
- templateBuilder.Append(" <script type="text/javascript">rn");
- templateBuilder.Append(" var data = { };rn");
- templateBuilder.Append(" ");
- templateBuilder.Append(rotatepicdata.ToString());
- templateBuilder.Append("rn");
- templateBuilder.Append(" var ri = new MzRotateImage();rn");
- templateBuilder.Append(" ri.dataSource = data;rn");
- templateBuilder.Append(" ri.width = 320;rn");
- templateBuilder.Append(" ri.height = 240;rn");
- templateBuilder.Append(" ri.interval = 3000;rn");
- templateBuilder.Append(" ri.duration = 2000;rn");
- templateBuilder.Append(" document.write(ri.render());rn");
- templateBuilder.Append(" </");
- templateBuilder.Append("script>rn");
- templateBuilder.Append(" <!--图片轮换代码结束-->rn");
- templateBuilder.Append(" </div>rn");
- } //end if
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="hot_topic s_clear">rn");
- templateBuilder.Append(" <h2>论坛热帖</h2>rn");
- templateBuilder.Append(" <div class="content s_clear">rn");
- templateBuilder.Append(" <dl style="display:none">rn");
- templateBuilder.Append(" <dt><a href="#"alt="" target="_blank"><img height="60" width="80" src="http://i3.dukuai.com/ypic/ct_hangzhou_house/2009/11/30/125424_58_20091129_8db73c149bce58dc8853jS65fwN0Cy5H.jpg" alt=""/></a>rn");
- templateBuilder.Append(" </dt>rn");
- templateBuilder.Append(" <dd>rn");
- templateBuilder.Append(" <a href="#" alt="杭州这边风景独好 江景房性价比大PK" target="_blank"/>rn");
- templateBuilder.Append(" <h4><a href="#" alt="杭州这边风景独好 江景房性价比大PK" target="_blank">这边风景独好 江景房性价比PK</a></h4>rn");
- templateBuilder.Append(" <p><a href="#" alt="杭州这边风景独好 江景房性价比大PK" target="_blank">仔细探寻杭州各大江景房,究竟谁家的性价比更卓越?</a></p>rn");
- templateBuilder.Append(" </dd>rn");
- templateBuilder.Append(" </dl>rn");
- templateBuilder.Append(" <ul>rn");
- int hottopicscount = Discuz.Aggregation.TopicAggregationData.GetForumAggerationHotTopics().Rows.Count;
-
- if (hottopicscount==0)
- {
- templateBuilder.Append(" <script language="JavaScript" type="text/javascript" src="tools/showtopics.aspx?aggregation=1&count=9&time=2&order=1"></");
- templateBuilder.Append("script>rn");
- }
- else
- {
- DataTable hottopicslist = Discuz.Aggregation.TopicAggregationData.GetForumAggerationHotTopics();
-
- int newhottopicinfo__loop__id=0;
- foreach(DataRow newhottopicinfo in hottopicslist.Rows)
- {
- newhottopicinfo__loop__id++;
- templateBuilder.Append(" <li>rn");
- templateBuilder.Append(" <span>rn");
- aspxrewriteurl = this.ShowForumAspxRewrite(Utils.StrToInt(newhottopicinfo["fid"].ToString().Trim(), 0),0,newhottopicinfo["forumnamerewritename"].ToString().Trim());
-
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">[" + newhottopicinfo["forumname"].ToString().Trim() + "]</a>rn");
- templateBuilder.Append(" </span>rn");
- aspxrewriteurl = this.ShowTopicAspxRewrite(newhottopicinfo["tid"].ToString().Trim(),0);
-
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank" title="" + newhottopicinfo["title"].ToString().Trim() + "">" + newhottopicinfo["title"].ToString().Trim() + "</a>rn");
- templateBuilder.Append(" </li>rn");
- } //end loop
- } //end if
- templateBuilder.Append(" </ul> rn");
- templateBuilder.Append(" <div class="ad_pic" style="padding-left:4px;"><div id="websitehottopicad"></div></div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="forum_slide">rn");
- templateBuilder.Append(" <div class="hot_forum">rn");
- templateBuilder.Append(" <div class="titlebar">rn");
- templateBuilder.Append(" <ul>rn");
- templateBuilder.Append(" <li id="li_hotforum" class="current"><a onclick="javascript:tabselect($('li_hotforum'));" href="javascript:;">热门版块</a></li>rn");
- templateBuilder.Append(" <li id="li_bbsmessage"><a onclick="javascript:tabselect($('li_bbsmessage'));" href="javascript:;">论坛信息</a></li>rn");
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="content">rn");
- templateBuilder.Append(" <ul id="hotforum">rn");
- int __foruminfo__loop__id=0;
- foreach(DataRow __foruminfo in forumagg.GetHotForumList(10).Rows)
- {
- __foruminfo__loop__id++;
- aspxrewriteurl = ShowForumAspxRewrite(Utils.StrToInt(__foruminfo["fid"].ToString().Trim(), 0),0, __foruminfo["rewritename"].ToString().Trim());
-
- templateBuilder.Append(" <li><em>" + __foruminfo["posts"].ToString().Trim() + "帖</em><cite rn");
- if (__foruminfo__loop__id==1)
- {
- templateBuilder.Append("class="first"rn");
- } //end if
- if (__foruminfo__loop__id==2)
- {
- templateBuilder.Append("class="second"rn");
- } //end if
- if (__foruminfo__loop__id==3)
- {
- templateBuilder.Append("class="third"rn");
- } //end if
- templateBuilder.Append(" > " + __foruminfo__loop__id.ToString() + "</cite><a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">" + __foruminfo["name"].ToString().Trim() + "</a></li>rn");
- } //end loop
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" <ul id="bbsmessage" style="display:none;">rn");
- templateBuilder.Append(" <li>会员总数: <i>");
- templateBuilder.Append(totalusers.ToString());
- templateBuilder.Append("</i>人</li>rn");
- templateBuilder.Append(" <li>最新注册会员:<i>rn");
- aspxrewriteurl = this.UserInfoAspxRewrite(lastuserid);
-
- templateBuilder.Append("<a href="");
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">");
- templateBuilder.Append(lastusername.ToString());
- templateBuilder.Append("</a></i></li>rn");
- templateBuilder.Append(" <li>主题数:<i>");
- templateBuilder.Append(totaltopic.ToString());
- templateBuilder.Append("</i>主题</li>rn");
- templateBuilder.Append(" <li>帖子数:<i>");
- templateBuilder.Append(totalpost.ToString());
- templateBuilder.Append("</i> 个(含回帖) </li>rn");
- templateBuilder.Append(" <li>今 日:<i>");
- templateBuilder.Append(todayposts.ToString());
- templateBuilder.Append("</i>帖 昨 日: <i>");
- templateBuilder.Append(yesterdayposts.ToString());
- templateBuilder.Append("</i> 帖</li>rn");
- if (highestpostsdate!="")
- {
- templateBuilder.Append(" <li> rn");
- templateBuilder.Append(" 最高日:<i>");
- templateBuilder.Append(highestposts.ToString());
- templateBuilder.Append("</i>帖rn");
- templateBuilder.Append(" </li>rn");
- templateBuilder.Append(" <li> rn");
- templateBuilder.Append(" 最高发帖日:<i>");
- templateBuilder.Append(highestpostsdate.ToString());
- templateBuilder.Append("</i>rn");
- templateBuilder.Append(" </li>rn");
- } //end if
- templateBuilder.Append(" <li>在线总数:<i>");
- templateBuilder.Append(totalonline.ToString());
- templateBuilder.Append("</i>人</li>rn");
- templateBuilder.Append(" <li>最高在线:<i>");
- templateBuilder.Append(highestonlineusercount.ToString());
- templateBuilder.Append("</i> 人 </li>rn");
- templateBuilder.Append(" <li>发生于:<i>");
- templateBuilder.Append(highestonlineusertime.ToString());
- templateBuilder.Append("</i></li>rn");
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div> rn");
- templateBuilder.Append(" <div id="websiteuserposttopad" class="ad_side"></div>rn");
- templateBuilder.Append(" <div class="forum_info">rn");
- templateBuilder.Append(" <div class="titlebar">rn");
- templateBuilder.Append(" <strong>发帖排行</strong>rn");
- templateBuilder.Append(" <ul class="posttime">rn");
- templateBuilder.Append(" <li id="li_postcount_day" class="current"><a onclick="javascript:tabselect($('li_postcount_day'));" href="javascript:;">日</a></li>rn");
- templateBuilder.Append(" <li id="li_postcount_week"><a onclick="javascript:tabselect($('li_postcount_week'));" href="javascript:;">周</a></li>rn");
- templateBuilder.Append(" <li id="li_postcount_month"><a onclick="javascript:tabselect($('li_postcount_month'));" href="javascript:;">月</a></li>rn");
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="content">rn");
- templateBuilder.Append(" <div id="postcount_month" class="postcount" style="display:none;">rn");
- userPostCountInfoList = forumagg.GetUserPostCountList(4, DateType.Month, 1);
-
- int userMonthPostCountInfo__loop__id=0;
- foreach(UserPostCountInfo userMonthPostCountInfo in userPostCountInfoList)
- {
- userMonthPostCountInfo__loop__id++;
- templateBuilder.Append(" <dl>rn");
- string avatarurl = Avatars.GetAvatarUrl(userMonthPostCountInfo.Uid, AvatarSize.Small);
-
- templateBuilder.Append(" <img src="");
- templateBuilder.Append(avatarurl.ToString());
- templateBuilder.Append("" onerror="this.onerror=null;this.src='");
- templateBuilder.Append(forumpath.ToString());
- templateBuilder.Append("templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/noavatar_small.gif';" alt="头像" " style="border:1px solid #E8E8E8;padding:1px;" />rn");
- templateBuilder.Append(" <dt>rn");
- aspxrewriteurl = this.UserInfoAspxRewrite(userMonthPostCountInfo.Uid);
-
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(userMonthPostCountInfo.Username,20,"..."));
- templateBuilder.Append("</a></dt>rn");
- templateBuilder.Append(" <dd>发帖<em>");
- templateBuilder.Append(userMonthPostCountInfo.PostCount.ToString().Trim());
- templateBuilder.Append("</em>篇</dd>rn");
- templateBuilder.Append(" </dl>rn");
- } //end loop
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div id="postcount_week" class="postcount" style="display:none;">rn");
- userPostCountInfoList = forumagg.GetUserPostCountList(4, DateType.Week, 1);
-
- int userWeekPostCountInfo__loop__id=0;
- foreach(UserPostCountInfo userWeekPostCountInfo in userPostCountInfoList)
- {
- userWeekPostCountInfo__loop__id++;
- templateBuilder.Append(" <dl>rn");
- string avatarurl = Avatars.GetAvatarUrl(userWeekPostCountInfo.Uid, AvatarSize.Small);
-
- templateBuilder.Append(" <img src="");
- templateBuilder.Append(avatarurl.ToString());
- templateBuilder.Append("" onerror="this.onerror=null;this.src='");
- templateBuilder.Append(forumpath.ToString());
- templateBuilder.Append("templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/noavatar_small.gif';" alt="头像" " style="border:1px solid #E8E8E8;padding:1px;" />rn");
- templateBuilder.Append(" <dt>rn");
- aspxrewriteurl = this.UserInfoAspxRewrite(userWeekPostCountInfo.Uid);
-
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(userWeekPostCountInfo.Username,20,"..."));
- templateBuilder.Append("</a></dt>rn");
- templateBuilder.Append(" <dd>发帖<em>");
- templateBuilder.Append(userWeekPostCountInfo.PostCount.ToString().Trim());
- templateBuilder.Append("</em>篇</dd>rn");
- templateBuilder.Append(" </dl>rn");
- } //end loop
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div id="postcount_day" class="postcount">rn");
- userPostCountInfoList = forumagg.GetUserPostCountList(4, DateType.Day, 1);
-
- int userDayPostCountInfo__loop__id=0;
- foreach(UserPostCountInfo userDayPostCountInfo in userPostCountInfoList)
- {
- userDayPostCountInfo__loop__id++;
- templateBuilder.Append(" <dl>rn");
- string avatarurl = Avatars.GetAvatarUrl(userDayPostCountInfo.Uid, AvatarSize.Small);
-
- templateBuilder.Append(" <img src="");
- templateBuilder.Append(avatarurl.ToString());
- templateBuilder.Append("" onerror="this.onerror=null;this.src='");
- templateBuilder.Append(forumpath.ToString());
- templateBuilder.Append("templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/noavatar_small.gif';" alt="头像" " style="border:1px solid #E8E8E8;padding:1px;" />rn");
- templateBuilder.Append(" <dt>rn");
- aspxrewriteurl = this.UserInfoAspxRewrite(userDayPostCountInfo.Uid);
-
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(userDayPostCountInfo.Username,20,"..."));
- templateBuilder.Append("</a></dt>rn");
- templateBuilder.Append(" <dd>发帖<em>");
- templateBuilder.Append(userDayPostCountInfo.PostCount.ToString().Trim());
- templateBuilder.Append("</em>篇</dd>rn");
- templateBuilder.Append(" </dl> rn");
- } //end loop
- templateBuilder.Append(" </div> rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<div id="websiterecforumtopad" class="ad s_clear"></div>rn");
- templateBuilder.Append("<script type="text/javascript">rn");
- templateBuilder.Append("var reco_topic = ");
- templateBuilder.Append(forumagg.GetTopicJsonFromFile().ToString().Trim());
- templateBuilder.Append(";rn");
- templateBuilder.Append("var templatepath = "");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("";rn");
- templateBuilder.Append("var aspxrewrite = ");
- templateBuilder.Append(config.Aspxrewrite.ToString().Trim());
- templateBuilder.Append(";rn");
- templateBuilder.Append("</");
- templateBuilder.Append("script>rn");
- int forumid__loop__id=0;
- foreach(int forumid in Discuz.Aggregation.AggregationFacade.ForumAggregation.GetRecommendForumID())
- {
- forumid__loop__id++;
- ForumInfo foruminfo = Forums.GetForumInfo(forumid);
-
- if (foruminfo!=null)
- {
- int tcount = Forums.GetForumList(forumid).Rows.Count!=0?12:8;
-
- templateBuilder.Append("<div class="forum_list s_clear forum">rn");
- templateBuilder.Append(" <div class="list_main">rn");
- templateBuilder.Append(" <div class="forum_topic s_clear rn");
- if (forumid__loop__id%2==0)
- {
- templateBuilder.Append("otherrn");
- } //end if
- templateBuilder.Append("">rn");
- templateBuilder.Append(" <h3>rn");
- templateBuilder.Append(" <cite>rn");
- int sub_forum__loop__id=0;
- foreach(DataRow sub_forum in Forums.GetForumList(forumid).Rows)
- {
- sub_forum__loop__id++;
- if (sub_forum__loop__id<=5)
- {
- aspxrewriteurl = this.ShowForumAspxRewrite(Utils.StrToInt(sub_forum["fid"].ToString().Trim(), 0),0,sub_forum["rewritename"].ToString().Trim());
-
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" tabindex="_blank">" + sub_forum["name"].ToString().Trim() + "</a>rn");
- } //end if
- } //end loop
- aspxrewriteurl = this.ShowForumAspxRewrite(forumid,0,foruminfo.Rewritename);
-
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" tabindex="_blank">更多>></a>rn");
- templateBuilder.Append(" </cite>rn");
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" tabindex="_blank">");
- templateBuilder.Append(foruminfo.Name.ToString().Trim());
- templateBuilder.Append("</a></h3>rn");
- templateBuilder.Append(" <div class="content main" rn");
- if (tcount==8)
- {
- templateBuilder.Append("style="height:180px"rn");
- } //end if
- templateBuilder.Append(">rn");
- templateBuilder.Append(" <div class="showpic">rn");
- templateBuilder.Append(" <script type="text/javascript">document.write(showtopicinfo(");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append(", " + forumid__loop__id.ToString() + "-1));</");
- templateBuilder.Append("script>rn");
- templateBuilder.Append(" </div>rn");
- int listcount = Discuz.Aggregation.TopicAggregationData.GetForumAggregationTopic(forumid).Rows.Count;
-
- topiclist = listcount==0?forumagg.GetForumTopicList(6, 0, forumid, TopicTimeType.All, TopicOrderType.PostDateTime, false, false):Discuz.Aggregation.TopicAggregationData.GetForumAggregationTopic(forumid);
-
- int listsize = listcount==0?6 :4;
-
- int newtopicinfo__loop__id=0;
- foreach(DataRow newtopicinfo in topiclist.Rows)
- {
- newtopicinfo__loop__id++;
- if (newtopicinfo__loop__id<=listsize)
- {
- if (listcount!=0 && newtopicinfo__loop__id==1)
- {
- aspxrewriteurl = this.ShowTopicAspxRewrite(newtopicinfo["topicid"].ToString().Trim(),0);
-
- templateBuilder.Append(" <div class="topic">rn");
- templateBuilder.Append(" <h2><a href="");
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">" + newtopicinfo["title"].ToString().Trim() + "</a></h2>rn");
- templateBuilder.Append(" <p><a href="");
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">" + newtopicinfo["shortdescription"].ToString().Trim() + "</a></p>rn");
- templateBuilder.Append(" </div>rn");
- continue;
- } //end if
- if (listcount!=0)
- {
- if (newtopicinfo__loop__id==2)
- {
- templateBuilder.Append(" <div class="topic_list">rn");
- templateBuilder.Append(" <ul id="topiclist_ul_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append(""> rn");
- } //end if
- }
- else
- {
- if (newtopicinfo__loop__id==1)
- {
- templateBuilder.Append(" <div class="topic_list">rn");
- templateBuilder.Append(" <ul>rn");
- } //end if
- } //end if
- templateBuilder.Append(" <li>rn");
- templateBuilder.Append(" <strong>rn");
- if (listcount==0)
- {
- aspxrewriteurl = this.ShowForumAspxRewrite(Utils.StrToInt(newtopicinfo["fid"].ToString().Trim(), 0),0);
-
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">[" + newtopicinfo["name"].ToString().Trim() + "]</a>rn");
- }
- else
- {
- aspxrewriteurl = ShowForumAspxRewrite(Utils.StrToInt(newtopicinfo["fid"].ToString().Trim(), 0),0);
-
- string name = Forums.GetForumInfo(Utils.StrToInt(newtopicinfo["fid"].ToString().Trim(), 0)).Name;
-
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">[");
- templateBuilder.Append(name.ToString());
- templateBuilder.Append("]</a>rn");
- } //end if
- templateBuilder.Append(" </strong>rn");
- if (listcount==0)
- {
- aspxrewriteurl = this.ShowTopicAspxRewrite(newtopicinfo["tid"].ToString().Trim(),0);
-
- }
- else
- {
- aspxrewriteurl = this.ShowTopicAspxRewrite(newtopicinfo["topicid"].ToString().Trim(),0);
-
- } //end if
- templateBuilder.Append(" <a title="" + newtopicinfo["title"].ToString().Trim() + "" href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(newtopicinfo["title"].ToString().Trim(),43,"..."));
- templateBuilder.Append("</a>rn");
- templateBuilder.Append(" </li> rn");
- if (newtopicinfo__loop__id==listsize)
- {
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div> rn");
- } //end if
- } //end if
- } //end loop
- if (listcount!=0 && listcount<4)
- {
- if (listcount==1)
- {
- templateBuilder.Append(" <div class="topic_list">rn");
- templateBuilder.Append(" <ul id="topiclist_ul_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append("">rn");
- } //end if
- if (listcount<6)
- {
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <script>rn");
- templateBuilder.Append(" function addhtmltoul()rn");
- templateBuilder.Append(" {rn");
- templateBuilder.Append(" var lihtml="";rn");
- topiclist = forumagg.GetForumTopicList(4-listcount, 0, forumid, TopicTimeType.All, TopicOrderType.PostDateTime, false, false);
-
- int newtopicinfos__loop__id=0;
- foreach(DataRow newtopicinfos in topiclist.Rows)
- {
- newtopicinfos__loop__id++;
- if (newtopicinfos__loop__id<=4-listcount)
- {
- templateBuilder.Append(" lihtml+='<li>';rn");
- templateBuilder.Append(" lihtml+='<strong>';rn");
- aspxrewriteurl = this.ShowForumAspxRewrite(Utils.StrToInt(newtopicinfos["fid"].ToString().Trim(), 0),0);
-
- templateBuilder.Append(" lihtml+='<a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">[" + newtopicinfos["name"].ToString().Trim() + "]</a>';rn");
- templateBuilder.Append(" lihtml+='</strong>';rn");
- aspxrewriteurl = this.ShowTopicAspxRewrite(newtopicinfos["tid"].ToString().Trim(),0);
-
- templateBuilder.Append(" lihtml+=' <a title="" + newtopicinfos["title"].ToString().Trim() + "" href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">" + newtopicinfos["title"].ToString().Trim() + "</a>'; rn");
- templateBuilder.Append(" lihtml+='</li>';rn");
- } //end if
- } //end loop
- templateBuilder.Append(" $('topiclist_ul_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append("').innerHTML+=(lihtml);rn");
- templateBuilder.Append(" }rn");
- templateBuilder.Append(" addhtmltoul();rn");
- templateBuilder.Append(" </");
- templateBuilder.Append("script>rn");
- } //end if
- } //end if
- if (Forums.GetForumList(forumid).Rows.Count!=0)
- {
- templateBuilder.Append(" <div class="topic_box"> rn");
- int subforum__loop__id=0;
- foreach(DataRow subforum in Forums.GetForumList(forumid).Rows)
- {
- subforum__loop__id++;
- if (subforum__loop__id<=3)
- {
- templateBuilder.Append(" <dl> rn");
- aspxrewriteurl = this.ShowForumAspxRewrite(Utils.StrToInt(subforum["fid"].ToString().Trim(), 0),0,subforum["rewritename"].ToString().Trim());
-
- templateBuilder.Append(" <dt><a href="");
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" tabindex="_blank">" + subforum["name"].ToString().Trim() + "</a></dt> rn");
- templateBuilder.Append(" <dd>" + subforum["description"].ToString().Trim() + "</dd>rn");
- templateBuilder.Append(" </dl>rn");
- } //end if
- } //end loop
- templateBuilder.Append(" </div>rn");
- } //end if
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="list_side">rn");
- templateBuilder.Append(" <div class="forum_side s_clear rn");
- if (forumid__loop__id%2==0)
- {
- templateBuilder.Append("otherrn");
- } //end if
- templateBuilder.Append("">rn");
- templateBuilder.Append(" <div class="titlebar">rn");
- templateBuilder.Append(" <ul>rn");
- templateBuilder.Append(" <li class="current" id="li_forum_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append("_topic"><a href="javascript:;" onclick="javascript:tabselect($('li_forum_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append("_topic'),");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append(");">最热主题</a></li>rn");
- templateBuilder.Append(" <li id="li_forum_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append("_reply"><a href="javascript:;" onclick="javascript:tabselect($('li_forum_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append("_reply'), ");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append(");">最新回复</a></li>rn");
- templateBuilder.Append(" <li id="li_forum_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append("_digest"><a href="javascript:;" onclick="javascript:tabselect($('li_forum_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append("_digest'), ");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append(");">精华</a></li>rn");
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="content s_clear" rn");
- if (tcount==8)
- {
- templateBuilder.Append("style="height:180px"rn");
- } //end if
- templateBuilder.Append("> rn");
- templateBuilder.Append(" <ul id="forum_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append("_topic" class="forum_hot_topic">rn");
- topiclist = forumagg.GetForumTopicList(tcount, 0, forumid, TopicTimeType.All, TopicOrderType.Replies, false, false);
-
- if (topiclist.Rows.Count>0)
- {
- int hottopicinfo__loop__id=0;
- foreach(DataRow hottopicinfo in topiclist.Rows)
- {
- hottopicinfo__loop__id++;
- aspxrewriteurl = this.ShowTopicAspxRewrite(hottopicinfo["tid"].ToString().Trim(),0);
-
- templateBuilder.Append(" <li><em>" + hottopicinfo["replies"].ToString().Trim() + "</em><a title="" + hottopicinfo["title"].ToString().Trim() + "" href="");
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("" target="_blank">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(hottopicinfo["title"].ToString().Trim(),28,"..."));
- templateBuilder.Append("</a></li> rn");
- } //end loop
- }
- else
- {
- templateBuilder.Append(" 暂无数据!rn");
- } //end if
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" <ul id="forum_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append("_reply" class="forum_hot_topic" style="display:none;">rn");
- topiclist = forumagg.GetForumTopicList(tcount, 0, forumid, TopicTimeType.All, TopicOrderType.LastPost, false, false);
-
- if (topiclist.Rows.Count>0)
- {
- int replytopic__loop__id=0;
- foreach(DataRow replytopic in topiclist.Rows)
- {
- replytopic__loop__id++;
- templateBuilder.Append(" <li><a title="" + replytopic["title"].ToString().Trim() + "" href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("showtopic.aspx?topicid=" + replytopic["tid"].ToString().Trim() + "&page=end#lastpost" target="_blank">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(replytopic["title"].ToString().Trim(),28,"..."));
- templateBuilder.Append("</a></li> rn");
- } //end loop
- }
- else
- {
- templateBuilder.Append(" 暂无数据!rn");
- } //end if
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" <ul id="forum_");
- templateBuilder.Append(forumid.ToString());
- templateBuilder.Append("_digest" class="forum_hot_topic" style="display:none;">rn");
- topiclist = forumagg.GetForumTopicList(tcount, 0, forumid, TopicTimeType.All, TopicOrderType.LastPost, true, false);
-
- if (topiclist.Rows.Count>0)
- {
- int replytopic__loop__id=0;
- foreach(DataRow replytopic in topiclist.Rows)
- {
- replytopic__loop__id++;
- templateBuilder.Append(" <li><a title="" + replytopic["title"].ToString().Trim() + "" href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("showtopic.aspx?topicid=" + replytopic["tid"].ToString().Trim() + "&page=end#lastpost" target="_blank">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(replytopic["title"].ToString().Trim(),28,"..."));
- templateBuilder.Append("</a></li> rn");
- } //end loop
- }
- else
- {
- templateBuilder.Append(" 暂无数据!rn");
- } //end if
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append("</div>rn");
- } //end if
- } //end loop
- templateBuilder.Append("<div id="websiterecforumbottomad" class="ad s_clear"></div>rn");
- if (Discuz.Plugin.Space.SpacePluginProvider.GetInstance()!=null)
- {
- if (config.Enablespace==1)
- {
- templateBuilder.Append("<div class="forum_list s_clear space">rn");
- templateBuilder.Append(" <div class="list_main">rn");
- templateBuilder.Append(" <div class="forum_topic s_clear other">rn");
- templateBuilder.Append(" <h3><cite><a href="spaceindex.aspx" target="_blank">空间首页>></a></cite>个人空间</h3>rn");
- templateBuilder.Append(" <div class="content main">rn");
- templateBuilder.Append(" <div class="showpic" style="position:relative;">rn");
- templateBuilder.Append(" <script type='text/javascript'>rn");
- templateBuilder.Append(" var imgwidth = 300;rn");
- templateBuilder.Append(" var imgheight = 140;rn");
- templateBuilder.Append(" </");
- templateBuilder.Append("script>rn");
- templateBuilder.Append(" <script type='text/javascript'>rn");
- templateBuilder.Append(" var data = {};rn");
- templateBuilder.Append(" ");
- templateBuilder.Append(spacerotatepicdata.ToString());
- templateBuilder.Append("rn");
- templateBuilder.Append(" var ri = new MzRotateImage();rn");
- templateBuilder.Append(" ri.dataSource = data;rn");
- templateBuilder.Append(" ri.width = 300;rn");
- templateBuilder.Append(" ri.height = 140;rn");
- templateBuilder.Append(" ri.interval = 3000;rn");
- templateBuilder.Append(" ri.duration = 2000;rn");
- templateBuilder.Append(" document.write(ri.render());rn");
- templateBuilder.Append(" </");
- templateBuilder.Append("script>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="topic_list"> rn");
- templateBuilder.Append(" <ul class="spacepost">rn");
- int __spacepostinfo__loop__id=0;
- foreach(SpaceShortPostInfo __spacepostinfo in spacepostlist)
- {
- __spacepostinfo__loop__id++;
- templateBuilder.Append(" <li><cite><a href="");
- templateBuilder.Append(spaceurl.ToString());
- templateBuilder.Append("space/?uid=");
- templateBuilder.Append(__spacepostinfo.Uid.ToString().Trim());
- templateBuilder.Append("" target="_blank">");
- templateBuilder.Append(__spacepostinfo.Author.ToString().Trim());
- templateBuilder.Append("</a></cite><a href="");
- templateBuilder.Append(spaceurl.ToString());
- templateBuilder.Append("space/viewspacepost.aspx?postid=");
- templateBuilder.Append(__spacepostinfo.Postid.ToString().Trim());
- templateBuilder.Append("">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(__spacepostinfo.Title,56,"..."));
- templateBuilder.Append("</a> </li>rn");
- } //end loop
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="space_list">rn");
- int __spaceconfig__loop__id=0;
- foreach(SpaceConfigInfoExt __spaceconfig in spaceconfigs)
- {
- __spaceconfig__loop__id++;
- if (__spaceconfig__loop__id<=3)
- {
- string avatarurl = Avatars.GetAvatarUrl(__spaceconfig.Userid,AvatarSize.Small);
-
- templateBuilder.Append(" <dl>rn");
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(spaceurl.ToString());
- templateBuilder.Append("space/?uid=");
- templateBuilder.Append(__spaceconfig.Userid.ToString().Trim());
- templateBuilder.Append("" target="_blank"><img src="");
- templateBuilder.Append(avatarurl.ToString());
- templateBuilder.Append("" alt="blogphoto" onerror="this.onerror=null;this.src='");
- templateBuilder.Append(forumpath.ToString());
- templateBuilder.Append("templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/noavatar_small.gif';"/></a>rn");
- templateBuilder.Append(" <dt><a href="");
- templateBuilder.Append(spaceurl.ToString());
- templateBuilder.Append("space/?uid=");
- templateBuilder.Append(__spaceconfig.Userid.ToString().Trim());
- templateBuilder.Append("">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(__spaceconfig.Spacetitle,20,"..."));
- templateBuilder.Append("</a></dt>rn");
- templateBuilder.Append(" <dd><a href="");
- templateBuilder.Append(spaceurl.ToString());
- templateBuilder.Append("space/viewspacepost.aspx?postid=");
- templateBuilder.Append(__spaceconfig.Postid.ToString().Trim());
- templateBuilder.Append("" target="_blank">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(__spaceconfig.Posttitle,30,"..."));
- templateBuilder.Append("</a></dd>rn");
- templateBuilder.Append(" </dl>rn");
- } //end if
- } //end loop
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="list_side">rn");
- templateBuilder.Append(" <div class="forum_side s_clear other">rn");
- templateBuilder.Append(" <div class="titlebar">rn");
- templateBuilder.Append(" <ul>rn");
- templateBuilder.Append(" <li id="li_space" class="current" ><a href="javascript:;" onclick="javascript:tabselect($('li_space'));">最新更新空间</a></li>rn");
- templateBuilder.Append(" <li id="li_spacecomment"><a href="javascript:;" onclick="javascript:tabselect($('li_spacecomment'));">最新评论</a></li>rn");
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="content s_clear">rn");
- templateBuilder.Append(" <ul id="spacecommentlist" class="topicdot" style="display:none;">rn");
- int comment__loop__id=0;
- foreach(DataRow comment in spaceagg.GetSpaceTopComments(13).Rows)
- {
- comment__loop__id++;
- templateBuilder.Append(" <li><a href="");
- templateBuilder.Append(spaceurl.ToString());
- templateBuilder.Append("space/viewspacepost.aspx?postid=" + comment["postid"].ToString().Trim() + "" target="_blank">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(Discuz.Common.Utils.HtmlEncode(comment["content"].ToString().Trim()),30,"..."));
- templateBuilder.Append("</a></li>rn");
- } //end loop
- templateBuilder.Append(" <!--<li><em>fanzjgw</em><a href="#">Discuz!NT程序发布</a></li>-->rn");
- templateBuilder.Append(" </ul> rn");
- templateBuilder.Append(" <div id="spacelist" class="postcount" >rn");
- int space__loop__id=0;
- foreach(DataRow space in spaceagg.GetRecentUpdateSpaceList(5).Rows)
- {
- space__loop__id++;
- if (space__loop__id<=5)
- {
- templateBuilder.Append(" <dl>rn");
- string avatarurl = Avatars.GetAvatarUrl(space["userid"].ToString().Trim(), AvatarSize.Small);
-
- templateBuilder.Append(" <img src="");
- templateBuilder.Append(avatarurl.ToString());
- templateBuilder.Append("" onerror="this.onerror=null;this.src='");
- templateBuilder.Append(forumpath.ToString());
- templateBuilder.Append("templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/noavatar_small.gif';" alt="头像" " style="border:1px solid #E8E8E8;padding:1px;" />rn");
- templateBuilder.Append(" <dt>rn");
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(spaceurl.ToString());
- templateBuilder.Append("space/?uid=" + space["userid"].ToString().Trim() + "" target="_blank">rn");
- templateBuilder.Append(Utils.GetUnicodeSubString(space["spacetitle"].ToString().Trim(),30,"..."));
- templateBuilder.Append("</a>rn");
- templateBuilder.Append(" </dt>rn");
- templateBuilder.Append(" <dd>日志<em>" + space["PostCount"].ToString().Trim() + "</em>篇</dd>rn");
- templateBuilder.Append(" </dl>rn");
- } //end if
- } //end loop
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append("</div>rn");
- } //end if
- } //end if
- if (Discuz.Plugin.Album.AlbumPluginProvider.GetInstance()!=null)
- {
- if (config.Enablealbum==1)
- {
- templateBuilder.Append("<div class="forum_list s_clear album">rn");
- templateBuilder.Append(" <div class="list_main">rn");
- templateBuilder.Append(" <div class="forum_topic s_clear other">rn");
- templateBuilder.Append(" <h3><cite>rn");
- int ac__loop__id=0;
- foreach(AlbumCategoryInfo ac in albumcategorylist)
- {
- ac__loop__id++;
- if (ac__loop__id<5)
- {
- templateBuilder.Append(" <a href="showalbumlist.aspx?cate=");
- templateBuilder.Append(ac.Albumcateid.ToString().Trim());
- templateBuilder.Append("" target="_blank">");
- templateBuilder.Append(ac.Title.ToString().Trim());
- templateBuilder.Append("</a>rn");
- } //end if
- } //end loop
- templateBuilder.Append(" <a href="albumindex.aspx" target="_blank">更多>></a></cite>相册</h3>rn");
- templateBuilder.Append(" <div class="content main">rn");
- templateBuilder.Append(" <div class="photo">rn");
- templateBuilder.Append(" <ul>rn");
- int photo__loop__id=0;
- foreach(PhotoInfo photo in recommendphotolist)
- {
- photo__loop__id++;
- if (photo__loop__id<=4)
- {
- templateBuilder.Append(" <li>rn");
- templateBuilder.Append(" <a href="showphoto.aspx?photoid=");
- templateBuilder.Append(photo.Photoid.ToString().Trim());
- templateBuilder.Append("" target="_blank"><img src="");
- templateBuilder.Append(photo.Filename.ToString().Trim());
- templateBuilder.Append("" onerror="this.onerror=null;this.src='templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/album/errorphoto.gif';" alt="");
- templateBuilder.Append(photo.Title.ToString().Trim());
- templateBuilder.Append("" title="");
- templateBuilder.Append(photo.Title.ToString().Trim());
- templateBuilder.Append("" height="100"/></a>rn");
- templateBuilder.Append(" <p><a href="showphoto.aspx?photoid=");
- templateBuilder.Append(photo.Photoid.ToString().Trim());
- templateBuilder.Append("" target="_blank">rn");
- if (photo.Title=="")
- {
- templateBuilder.Append("暂无标题rn");
- }
- else
- {
- templateBuilder.Append(photo.Title.ToString().Trim());
- templateBuilder.Append("rn");
- } //end if
- templateBuilder.Append("</a></p>rn");
- templateBuilder.Append(" </li>rn");
- } //end if
- } //end loop
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="album_list"> rn");
- int __albuminfo__loop__id=0;
- foreach(AlbumInfo __albuminfo in recommendalbumlist)
- {
- __albuminfo__loop__id++;
- if (__albuminfo__loop__id<=4)
- {
- templateBuilder.Append(" <dl>rn");
- templateBuilder.Append(" <dd>rn");
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(albumurl.ToString());
- templateBuilder.Append("showalbum.aspx?albumid=");
- templateBuilder.Append(__albuminfo.Albumid.ToString().Trim());
- templateBuilder.Append("">rn");
- if (__albuminfo.Logo!="")
- {
- templateBuilder.Append(" <img src="");
- templateBuilder.Append(__albuminfo.Logo.ToString().Trim());
- templateBuilder.Append("" alt="");
- templateBuilder.Append(__albuminfo.Title.ToString().Trim());
- templateBuilder.Append("" style="height: 100px; width: 120px"/>rn");
- }
- else
- {
- templateBuilder.Append(" <img src="templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/NoPhoto.jpg" alt="");
- templateBuilder.Append(__albuminfo.Albumid.ToString().Trim());
- templateBuilder.Append("" style="height: 75px; width: 115px"/>rn");
- } //end if
- templateBuilder.Append(" </a>rn");
- templateBuilder.Append(" </dd>rn");
- templateBuilder.Append(" <dt><a href="");
- templateBuilder.Append(albumurl.ToString());
- templateBuilder.Append("showalbum.aspx?albumid=");
- templateBuilder.Append(__albuminfo.Albumid.ToString().Trim());
- templateBuilder.Append("" target="_blank">");
- templateBuilder.Append(__albuminfo.Title.ToString().Trim());
- templateBuilder.Append("</a></dt>rn");
- templateBuilder.Append(" </dl>rn");
- } //end if
- } //end loop
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="list_side">rn");
- templateBuilder.Append(" <div class="forum_side s_clear other">rn");
- templateBuilder.Append(" <div class="titlebar">rn");
- templateBuilder.Append(" <ul>rn");
- templateBuilder.Append(" <li class="current" id="li_album"><a href="javascript:;" onclick="javascript:tabselect($('li_album'));">热门相册</a></li>rn");
- templateBuilder.Append(" <li id="li_photo"><a href="javascript:;" onclick="javascript:tabselect($('li_photo'));">热门相片</a></li>rn");
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <div class="content s_clear">rn");
- templateBuilder.Append(" <ul id="albumlist" class="forum_hot_topic">rn");
- albumlist = albumagg.GetAlbumList(photoconfig.Focusalbumshowtype, 7, 180);
-
- if (albumlist.Count>0)
- {
- int hotalbuminfo__loop__id=0;
- foreach(AlbumInfo hotalbuminfo in albumlist)
- {
- hotalbuminfo__loop__id++;
- templateBuilder.Append(" <li><a href="showalbum.aspx?albumid=");
- templateBuilder.Append(hotalbuminfo.Albumid.ToString().Trim());
- templateBuilder.Append("" target="_blank">");
- templateBuilder.Append(hotalbuminfo.Title.ToString().Trim());
- templateBuilder.Append("</a> (<a href="showalbumlist.aspx?uid=");
- templateBuilder.Append(hotalbuminfo.Userid.ToString().Trim());
- templateBuilder.Append("">");
- templateBuilder.Append(hotalbuminfo.Username.ToString().Trim());
- templateBuilder.Append("</a>)</li>rn");
- } //end loop
- }
- else
- {
- templateBuilder.Append(" 暂无数据!rn");
- } //end if
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" <ul id="photolist" class="forum_hot_topic" style="display:none;">rn");
- templateBuilder.Append(" <!--一周热图总排行-->rn");
- photolist = albumagg.GetWeekHotPhotoList(photoconfig.Weekhot);
-
- if (photolist.Count>0)
- {
- int __photolist__loop__id=0;
- foreach(PhotoInfo __photolist in photolist)
- {
- __photolist__loop__id++;
- templateBuilder.Append(" <li><em>");
- templateBuilder.Append(__photolist.Views.ToString().Trim());
- templateBuilder.Append("</em><a href="showphoto.aspx?photoid=");
- templateBuilder.Append(__photolist.Photoid.ToString().Trim());
- templateBuilder.Append("" target="_blank">");
- templateBuilder.Append(__photolist.Title.ToString().Trim());
- templateBuilder.Append("</a> (<a href="showalbumlist.aspx?uid=");
- templateBuilder.Append(__photolist.Userid.ToString().Trim());
- templateBuilder.Append("">");
- templateBuilder.Append(__photolist.Username.ToString().Trim());
- templateBuilder.Append("</a>)</li>rn");
- } //end loop
- }
- else
- {
- templateBuilder.Append(" 暂无数据!rn");
- } //end if
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append("</div>rn");
- } //end if
- } //end if
- templateBuilder.Append("<div id="websiterecalbumAd" class="ad s_clear"></div>rn");
- if (forumlinkcount>0)
- {
- templateBuilder.Append("<div class="box links" id="forumlinks">rn");
- templateBuilder.Append(" <h4>友情链接</h4>rn");
- bool forumlinkend = false;
-
- int forumlink__loop__id=0;
- foreach(DataRow forumlink in forumlinklist.Rows)
- {
- forumlink__loop__id++;
- if (forumlink__loop__id==1)
- {
- templateBuilder.Append(" <div class="forumlinks"> rn");
- templateBuilder.Append(" <ul> rn");
- } //end if
- if (forumlink["logo"].ToString().Trim()!="")
- {
- templateBuilder.Append(" <li>rn");
- templateBuilder.Append(" <a href="" + forumlink["url"].ToString().Trim() + "" target="_blank"><img src="" + forumlink["logo"].ToString().Trim() + "" alt="" + forumlink["name"].ToString().Trim() + "" class="forumlink_logo"/></a>rn");
- templateBuilder.Append(" <h5><a href="" + forumlink["url"].ToString().Trim() + "" target="_blank">" + forumlink["name"].ToString().Trim() + "</a></h5>rn");
- templateBuilder.Append(" <p>" + forumlink["note"].ToString().Trim() + "</p>rn");
- templateBuilder.Append(" </li>rn");
- }
- else if (forumlink["name"].ToString().Trim()!="$$otherlink$$")
- {
- templateBuilder.Append(" <li>rn");
- templateBuilder.Append(" <h5>rn");
- templateBuilder.Append(" <a href="" + forumlink["url"].ToString().Trim() + "" target="_blank">" + forumlink["name"].ToString().Trim() + "</a>rn");
- templateBuilder.Append(" </h5>rn");
- templateBuilder.Append(" <p>" + forumlink["note"].ToString().Trim() + "</p>rn");
- templateBuilder.Append(" </li>rn");
- }
- else
- {
- if (forumlinkend==false)
- {
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- forumlinkend = true;
-
- } //end if
- templateBuilder.Append(" <div class="" + forumlink["url"].ToString().Trim() + "">rn");
- templateBuilder.Append(" " + forumlink["note"].ToString().Trim() + "rn");
- templateBuilder.Append(" </div>rn");
- } //end if
- } //end loop
- if (forumlinkend==false)
- {
- templateBuilder.Append(" </ul>rn");
- templateBuilder.Append(" </div>rn");
- } //end if
- templateBuilder.Append("</div>rn");
- } //end if
- templateBuilder.Append("</div>rn");
- }
- else
- {
- templateBuilder.Append("<div class="wrap s_clear" id="wrap">rn");
- templateBuilder.Append("<div class="main">rn");
- templateBuilder.Append(" <div class="msgbox">rn");
- templateBuilder.Append(" <h1>出现了");
- templateBuilder.Append(page_err.ToString());
- templateBuilder.Append("个错误</h1>rn");
- templateBuilder.Append(" <hr class="solidline"/>rn");
- templateBuilder.Append(" <div class="msg_inner error_msg">rn");
- templateBuilder.Append(" <p>");
- templateBuilder.Append(msgbox_text.ToString());
- templateBuilder.Append("</p>rn");
- templateBuilder.Append(" <p class="errorback">rn");
- templateBuilder.Append(" <script type="text/javascript">rn");
- templateBuilder.Append(" if(");
- templateBuilder.Append(msgbox_showbacklink.ToString());
- templateBuilder.Append(")rn");
- templateBuilder.Append(" {rn");
- templateBuilder.Append(" document.write("<a href=\"");
- templateBuilder.Append(msgbox_backlink.ToString());
- templateBuilder.Append("\">返回上一步</a> |   ");rn");
- templateBuilder.Append(" }rn");
- templateBuilder.Append(" </");
- templateBuilder.Append("script>rn");
- templateBuilder.Append(" <a href="forumindex.aspx">论坛首页</a>rn");
- if (usergroupid==7)
- {
- templateBuilder.Append(" | <a href="login.aspx">登录</a> | <a href="register.aspx">注册</a>rn");
- } //end if
- templateBuilder.Append(" </p>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("</div>rn");
- } //end if
- string webSiteBottomAd = Advertisements.GetWebSiteAd(AdType.WebSiteBottomAd);
-
- if (infloat!=1)
- {
- if (pagename=="website.aspx")
- {
- templateBuilder.Append(" <div id="websitebottomad"></div>rn");
- }
- else if (footerad!="")
- {
- templateBuilder.Append(" <div id="ad_footerbanner">");
- templateBuilder.Append(footerad.ToString());
- templateBuilder.Append("</div> rn");
- } //end if
- if (headerad!="")
- {
- templateBuilder.Append("<div id="ad_headerbanner_nodisplay" style="display:none">");
- templateBuilder.Append(headerad.ToString());
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<script type="text/javascript">rn");
- templateBuilder.Append("$('ad_headerbanner').innerHTML = $('ad_headerbanner_nodisplay').innerHTML;rn");
- templateBuilder.Append("$('ad_headerbanner_nodisplay').parentNode.removeChild($('ad_headerbanner_nodisplay'));rn");
- templateBuilder.Append("</");
- templateBuilder.Append("script>rn");
- } //end if
- templateBuilder.Append("<div id="footer">rn");
- templateBuilder.Append(" <div class="wrap">rn");
- templateBuilder.Append(" <div id="footlinks">rn");
- templateBuilder.Append(" <p><a href="");
- templateBuilder.Append(config.Weburl.ToString().Trim());
- templateBuilder.Append("" target="_blank">");
- templateBuilder.Append(config.Webtitle.ToString().Trim());
- templateBuilder.Append("</a> - ");
- templateBuilder.Append(config.Linktext.ToString().Trim());
- templateBuilder.Append(" - <a target="_blank" href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("stats.aspx">统计</a> - rn");
- if (config.Sitemapstatus==1)
- {
- templateBuilder.Append(" <a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("tools/sitemap.aspx" target="_blank" title="百度论坛收录协议">Sitemap</a>rn");
- } //end if
- templateBuilder.Append(" ");
- templateBuilder.Append(config.Statcode.ToString().Trim());
- templateBuilder.Append(config.Icp.ToString().Trim());
- templateBuilder.Append("rn");
- templateBuilder.Append(" </p>rn");
- templateBuilder.Append(" <div>rn");
- templateBuilder.Append(" <a href="http://www.comsenz.com/" target="_blank">Comsenz Technology Ltd</a>rn");
- templateBuilder.Append(" - <a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("archiver/index.aspx" target="_blank">简洁版本</a>rn");
- if (config.Stylejump==1)
- {
- if (userid!=-1 || config.Guestcachepagetimeout<=0)
- {
- templateBuilder.Append(" - <span id="styleswitcher" class="drop" onmouseover="showMenu(this.id)" onclick="window.location.href='");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("showtemplate.aspx'">界面风格</span>rn");
- templateBuilder.Append(" <ul id="styleswitcher_menu" class="popupmenu_popup s_clear" style="display: none;">rn");
- templateBuilder.Append(" ");
- templateBuilder.Append(templatelistboxoptions.ToString());
- templateBuilder.Append("rn");
- templateBuilder.Append(" </ul>rn");
- } //end if
- } //end if
- templateBuilder.Append(" - <span class="scrolltop" onclick="window.scrollTo(0,0);">TOP</span>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append(" <a title="Powered by Discuz!NT" target="_blank" href="http://nt.discuz.net"><img border="0" alt="Discuz!NT" src="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append("templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/discuznt_logo.gif"/></a>rn");
- templateBuilder.Append(" <p id="copyright">rn");
- templateBuilder.Append(" Powered by <strong><a href="http://nt.discuz.net" target="_blank" title="Discuz!NT 3.1.0 (.NET Framework 2.0/3.x)">Discuz!NT</a></strong> <em class="f_bold">3.1.0</em>rn");
- if (config.Licensed==1)
- {
- templateBuilder.Append(" (<a href="" onclick="this.href='http://nt.discuz.net/certificate/?host='+location.href.substring(0, location.href.lastIndexOf('/'))" target="_blank">Licensed</a>)rn");
- } //end if
- templateBuilder.Append(" ");
- templateBuilder.Append(config.Forumcopyright.ToString().Trim());
- templateBuilder.Append("rn");
- templateBuilder.Append(" </p>rn");
- templateBuilder.Append(" <p id="debuginfo" class="grayfont">rn");
- if (config.Debug!=0)
- {
- templateBuilder.Append(" Processed in ");
- templateBuilder.Append(this.Processtime.ToString().Trim());
- templateBuilder.Append(" second(s)rn");
- if (isguestcachepage==1)
- {
- templateBuilder.Append(" (Cached).rn");
- }
- else if (querycount>1)
- {
- templateBuilder.Append(" , ");
- templateBuilder.Append(querycount.ToString());
- templateBuilder.Append(" queries.rn");
- }
- else
- {
- templateBuilder.Append(" , ");
- templateBuilder.Append(querycount.ToString());
- templateBuilder.Append(" query.rn");
- } //end if
- } //end if
- templateBuilder.Append(" </p>rn");
- templateBuilder.Append(" </div>rn");
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<ul id="quicksearch_menu" class="popupmenu_popup" style="display: none;">rn");
- templateBuilder.Append(" <li onclick="$('keywordtype').value='0';$('quicksearch').innerHTML='帖子标题';$('quicksearch_menu').style.display='none';" onmouseover="MouseCursor(this);">帖子标题</li>rn");
- if (config.Enablespace==1)
- {
- templateBuilder.Append(" <li onclick="$('keywordtype').value='2';$('quicksearch').innerHTML='空间日志';$('quicksearch_menu').style.display='none';" onmouseover="MouseCursor(this);">空间日志</li>rn");
- } //end if
- if (config.Enablealbum==1)
- {
- templateBuilder.Append(" <li onclick="$('keywordtype').value='3';$('quicksearch').innerHTML='相册标题';$('quicksearch_menu').style.display='none';" onmouseover="MouseCursor(this);">相册标题</li>rn");
- } //end if
- templateBuilder.Append(" <li onclick="$('keywordtype').value='8';$('quicksearch').innerHTML='作者';$('quicksearch_menu').style.display='none';" onmouseover="MouseCursor(this);">作者</li>rn");
- templateBuilder.Append(" <li onclick="$('keywordtype').value='9';$('quicksearch').innerHTML='版块';$('quicksearch_menu').style.display='none';" onmouseover="MouseCursor(this);">版块</li>rn");
- templateBuilder.Append("</ul>rn");
- templateBuilder.Append("<ul class="popupmenu_popup" id="viewpro_menu" style="display: none">rn");
- templateBuilder.Append(" <li style="text-align:center;"><img src="");
- templateBuilder.Append(useravatar.ToString());
- templateBuilder.Append("" onerror="this.onerror=null;this.src='templates/");
- templateBuilder.Append(templatepath.ToString());
- templateBuilder.Append("/images/noavatar_small.gif';" /></li>rn");
- aspxrewriteurl = this.UserInfoAspxRewrite(userid);
-
- templateBuilder.Append(" <li class="popuser"><a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(aspxrewriteurl.ToString());
- templateBuilder.Append("">我的资料</a></li>rn");
- if (config.Enablespace==1)
- {
- templateBuilder.Append(" <li class="poplink"><a href="");
- templateBuilder.Append(forumurl.ToString());
- templateBuilder.Append(spaceurl.ToString());
- templateBuilder.Append("space/">我的空间</a></li>rn");
- } //end if
- templateBuilder.Append("</ul>rn");
- int prentid__loop__id=0;
- foreach(string prentid in mainnavigationhassub)
- {
- prentid__loop__id++;
- templateBuilder.Append("<ul class="popupmenu_popup headermenu_popup" id="menu_");
- templateBuilder.Append(prentid.ToString());
- templateBuilder.Append("_menu" style="display: none">rn");
- int subnav__loop__id=0;
- foreach(DataRow subnav in subnavigation.Rows)
- {
- subnav__loop__id++;
- bool isoutput = false;
-
- if (subnav["parentid"].ToString().Trim()==prentid)
- {
- if (subnav["level"].ToString().Trim()=="0")
- {
- isoutput = true;
-
- }
- else
- {
- if (subnav["level"].ToString().Trim()=="1" && userid!=-1)
- {
- isoutput = true;
-
- }
- else
- {
- bool leveluseradmindi = true;
-
- leveluseradmindi = (useradminid==3 || useradminid==1 || useradminid==2);
-
- if (subnav["level"].ToString().Trim()=="2" && leveluseradmindi)
- {
- isoutput = true;
-
- } //end if
- if (subnav["level"].ToString().Trim()=="3" && useradminid==1)
- {
- isoutput = true;
-
- } //end if
- } //end if
- } //end if
- } //end if
- if (isoutput)
- {
- if (subnav["id"].ToString().Trim()=="11" || subnav["id"].ToString().Trim()=="12")
- {
- if (config.Statstatus==1)
- {
- templateBuilder.Append(" " + subnav["nav"].ToString().Trim() + "rn");
- continue;
- }
- else
- {
- continue;
- } //end if
- } //end if
- if (subnav["id"].ToString().Trim()=="18")
- {
- if (config.Oltimespan>0)
- {
- templateBuilder.Append(" " + subnav["nav"].ToString().Trim() + "rn");
- continue;
- }
- else
- {
- continue;
- } //end if
- } //end if
- if (subnav["id"].ToString().Trim()=="24")
- {
- if (config.Enablespace==1)
- {
- templateBuilder.Append(" " + subnav["nav"].ToString().Trim() + "rn");
- continue;
- }
- else
- {
- continue;
- } //end if
- } //end if
- if (subnav["id"].ToString().Trim()=="25")
- {
- if (config.Enablealbum==1)
- {
- templateBuilder.Append(" " + subnav["nav"].ToString().Trim() + "rn");
- continue;
- }
- else
- {
- continue;
- } //end if
- } //end if
- if (subnav["id"].ToString().Trim()=="26")
- {
- if (config.Enablemall>=1)
- {
- templateBuilder.Append(" " + subnav["nav"].ToString().Trim() + "rn");
- continue;
- }
- else
- {
- continue;
- } //end if
- } //end if
- templateBuilder.Append(" " + subnav["nav"].ToString().Trim() + "rn");
- } //end if
- } //end loop
- templateBuilder.Append("</ul>rn");
- } //end loop
- string webSiteHeaderAd = Advertisements.GetWebSiteAd(AdType.WebSiteHeaderAd);
-
- string webSiteHotTopicAd = Advertisements.GetWebSiteAd(AdType.WebSiteHotTopicAd);
-
- string webSiteUserPostTopAd = Advertisements.GetWebSiteAd(AdType.WebSiteUserPostTopAd);
-
- string webSiteRecForumTopAd = Advertisements.GetWebSiteAd(AdType.WebSiteRecForumTopAd);
-
- string webSiteRecForumBottomAd = Advertisements.GetWebSiteAd(AdType.WebSiteRecForumBottomAd);
-
- string webSiteRecAlbumAd = Advertisements.GetWebSiteAd(AdType.WebSiteRecAlbumAd);
-
- templateBuilder.Append("<div id="websiteheaderad_nodisplay" style="display:none">");
- templateBuilder.Append(webSiteHeaderAd.ToString());
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<div id="websitehottopicad_nodisplay" style="display:none">");
- templateBuilder.Append(webSiteHotTopicAd.ToString());
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<div id="websiteuserposttopad_nodisplay" style="display:none">");
- templateBuilder.Append(webSiteUserPostTopAd.ToString());
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<div id="websiterecforumtopad_nodisplay" style="display:none">");
- templateBuilder.Append(webSiteRecForumTopAd.ToString());
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<div id="websiterecforumbottomad_nodisplay" style="display:none">");
- templateBuilder.Append(webSiteRecForumBottomAd.ToString());
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<div id="websiterecalbumAd_nodisplay" style="display:none">");
- templateBuilder.Append(webSiteRecAlbumAd.ToString());
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<div id="websitebottomad_nodisplay" style="display:none">");
- templateBuilder.Append(webSiteBottomAd.ToString());
- templateBuilder.Append("</div>rn");
- templateBuilder.Append("<script type="text/javascript">rn");
- templateBuilder.Append("var adDiv = ["websiteheaderad", "websitehottopicad", "websiteuserposttopad", "websiterecforumtopad", "websiterecforumbottomad", "websiterecalbumAd", "websitebottomad"];rn");
- templateBuilder.Append("for (var i = 0; i < adDiv.length; i++) {rn");
- templateBuilder.Append(" if ($(adDiv[i] + '_nodisplay').innerHTML == '')rn");
- templateBuilder.Append(" $(adDiv[i]).style.display = 'none';rn");
- templateBuilder.Append(" else {rn");
- templateBuilder.Append(" $(adDiv[i]).innerHTML = $(adDiv[i] + '_nodisplay').innerHTML;rn");
- templateBuilder.Append(" $(adDiv[i] + '_nodisplay').parentNode.removeChild($(adDiv[i] + '_nodisplay'));rn");
- templateBuilder.Append(" }rn");
- templateBuilder.Append("}rn");
- templateBuilder.Append("</");
- templateBuilder.Append("script>rn");
- if (floatad!="")
- {
- templateBuilder.Append(" <script type="text/javascript" src="javascript/template_floatadv.js"></");
- templateBuilder.Append("script>rn");
- templateBuilder.Append(" ");
- templateBuilder.Append(floatad.ToString());
- templateBuilder.Append("rn");
- templateBuilder.Append(" <script type="text/javascript">theFloaters.play();</");
- templateBuilder.Append("script>rn");
- }
- else if (doublead!="")
- {
- templateBuilder.Append(" <script type="text/javascript" src="javascript/template_floatadv.js"></");
- templateBuilder.Append("script>rn");
- templateBuilder.Append(" ");
- templateBuilder.Append(doublead.ToString());
- templateBuilder.Append("rn");
- templateBuilder.Append(" <script type="text/javascript">theFloaters.play();</");
- templateBuilder.Append("script>rn");
- } //end if
- templateBuilder.Append("</body>rn");
- templateBuilder.Append("</html>rn");
- }
- else
- {
- templateBuilder.Append("]]></root>rn");
- } //end if
- Response.Write(templateBuilder.ToString());
- }
- </script>