⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 votelist.asp

📁 程序网络论坛HigroupBBS v4.00 默认管理员帐号密码都是Marcos
💻 ASP
字号:
<!--#include file="MarcosCB.asp"-->
<%
	dim i,boardId
	dim str,url,page,pageCode,pageTitle,pageOther,pageCountList

	getConn()
	str=getMainCode(mySkinId)
	page=getPost("page")

	if not isNumeric(page) then
		page=1
	end if

	pageTitle="<a href=""javascript:location.reload();"">投票列表</a>"
	pageOther="<script>document.title+=' - 查看系统投票列表';</script>"
	nowWhere "系统投票列表","voteList.asp"
	
	showHead str,pageTitle,pageOther
	showBody()
	showFoot(str)
	
	sub showBody()
		dim rs_sys
		dim str,body,theBody,tableEnd,tableStart
		
		pageCode=getPageCode(mySkinId,"PageList")
		PageList=split(pageCode,"$$$")
		
		sql="select * from Marcos_Vote order by isTop,lastVoteTime desc"
		rs.open sql,conn,1,1
		if not rs.eof then
			rs.absolutePage=page
		 else
			str="<tr height=""180""><td align=center colspan=5>暂时没有任何投票</td></tr>"
		end if
		for i=1 to 10
			if i>rs.pageCount then
				exit for
			end if
			pageCountList=pageCountList & "<a href=""?page=" & i & """><font {$font"&i&"}>" & i & "</font></a> "
		next
		
		pageCountList=replace(pageCountList,"{$font"&page&"}","class=warningColor")
		
		if rs.pageCount>=1 then
			pageCountList=pageCountList & "跳转到<select name=page onChange=""this.form.submit();"">"
			for i=1 to rs.pageCount
				pageCountList=pageCountList & "<option value=""" & i & """ {$selected" & i & "}>第" & i & "页</option>"
			next
			pageCountList=pageCountList & "</select>"
			pageCountList=replace(pageCountList,"{$selected" & page & "}","selected")
		end if
		
		for i=1 to listNum
			if rs.eof then exit for
			body=PageList(1)
			body=replace(body,"{$userName}",rs("userName"))
			body=replace(body,"{$replyPageList}","")
			body=replace(body,"{$replyCount}",rs("voteCount"))
			body=replace(body,"{$visitCount}",rs("visitCount"))
			body=replace(body,"{$updateTime}",rs("lastVoteTime"))
			str_sys=getStatusImg(rs("voteCount"))
			body=replace(body,"{$statusImg}",split(str_sys,"$$$")(0))
			body=replace(body,"{$statusTitle}",split(str_sys,"$$$")(1))
			body=replace(body,"{$lastPostInfo}","")
			if len(rs("voteTitle"))<=21 then
				voteTitle=encodeStr(rs("voteTitle"))
			 else
				voteTitle=left(encodeStr(rs("voteTitle")),21) & "..."
			end if
			if rs("isTop")=true then
				voteTitle="<font class=""warningColor"">[置顶]</font>"&voteTitle
			end if
			body=replace(body,"{$topicTitle}",voteTitle)
			body=replace(body,"{$topicLink}","voteShow.asp?voteId=" & rs("voteId"))
			body=replace(body,"{$mood}","&nbsp;<img src=""" & rs("voteMood") & """ border=0>")
			if fixNull(rs("votedUser"))="" then
				updateUser="暂无投票"
			 else
				updateUser=split(fixNull(rs("votedUser")),"$$$")(uBound(split(fixNull(rs("votedUser")),"$$$")))
			end if
			body=replace(body,"{$updateUser}",updateUser)
			str=str&body
			rs.movenext
		next
		rs.close
		queryTimes=queryTimes+1
		echo replace(PageList(0),"回复","票数")
		echo str
		newTopic="<img src=""Images/{$styleRoot}/newTopic.gif""><a href=""newVote.asp?theAct=new"">发起投票</a>"
		body=replace(PageList(2),"{$newTopic}",newTopic)
		body=replace(body,"{$pageList}",pageCountList)
		echo body
	end sub
	
	closeConn()
%>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -