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

📄 forum.asp

📁 商会 商会 商会 商会 商会 商会 商会 商会 商会 商会 商会 商会 商会
💻 ASP
📖 第 1 页 / 共 2 页
字号:
			 sql="select top 1 keyno,title,replytime,replyuser from forum where classcode='"+rs(0)+"' and grade=1 order by replyno desc"
			 rs2.Open sql,cn,1,1
			 if not rs2.EOF then
				keyno2=rs2("keyno")
				title2=trim(rs2("title"))
				replyuser=trim(rs2("replyuser"))
				date2=rs2("replytime")
			 else
				keyno2=""
			 end if
			 rs2.Close
			 if i mod 2=0 then
				bg1="#f6f6f6"
			 else
				bg1="#f3f3f3"
			 end if
			%>
              <tr bgcolor="<%=bg1%>"> 
	            <td width="40" align="center" height="70" class="font2" bgcolor="#eeeeee">
		   		<%if (datediff("d",date2,now()))<=1  and keyno2<>"" then%>
					<img src="images/on.gif"></td>
				<%else%>
					<img src="images/off.gif"></td>
				<%end if%>
                <td height=66 bgcolor="#f6f6f6">
		            <table width="98%" border="0" cellspacing="0" cellpadding="0" align="center">
				      <tr> 
						<td><a href="forum_list.asp?classcode=<%=rs(0)%>" class="a11"><b><font color="#000000"><%=trim(rs("classname"))%></font></b></a></td>
						<td>&nbsp;</td>
					 </tr>
					</table>
					<table width="98%" border="0" cellspacing="0" cellpadding="0" align="center">
						<tr> 
							<td height="6"></td>
						</tr>
						<tr> 
							<td><%=checkstr(trim(rs("content")),"1")%></td>
						</tr>
					</table>
                </td>
                <td align="center" width=50 bgcolor="#eeeeee"><%=rs("topcount")%></td>
                <td align="center" width=50 bgcolor="#f6f6f6"><%=rs("reccount")%></td>
                <td align="left" width="220" bgcolor="#eeeeee">
                  <table width="98%" border="0" cellspacing="0" cellpadding="0" align="center" style="line-height:20px">
					<%
					if keyno2<>"" then
					%>
                    <tr> 
                      <td>主题:<a href="forum_display.asp?keyno=<%=keyno2%>" class="a01"><%=Server.HTMLEncode(left(title2,15))%></a></td>
                    </tr>  
                    <tr> 
                      <td>作者:<a href="user_display.asp?usercode=<%=replyuser%>" target=_blank><%=replyuser%></a></td>
                    </tr>  
                    <tr> 
                      <td>日期:<%=date2%></td>
                    </tr>
					<%
					end if
					%>
                  </table>
				</td>
                <td align="center" width=90 bgcolor="#f6f6f6">
               <%
               	manager=trim(rs("manager"))
               	keyword=manager+"/"
				manager=""
				xx1=1
				xx2=instr(xx1,keyword,chr(47))
				wheretxt=""
				do while xx2>0
					ttt=mid(keyword,xx1,xx2-xx1)
					if ttt<>"" then
						sql="select userno from userinfo where state='1' and usercode='"+ttt+"'"
						rs2.Open sql,cn,1,1
						if not rs2.EOF then
							if cstr(Session("userno"))=cstr(rs2(0)) then
								userqx="1"
							end if
							ttt="<a href='user_display.asp?userno="&rs2(0)&"' target=_blank>"+ttt+"</a>"
							if manager="" then
								manager=ttt
							else
								manager=manager+"<br>"+ttt 	
							end if
						end if	
						rs2.Close
					end if
					xx1=xx2+1
					xx2=instr(xx1,keyword,"/")
				loop
				Response.Write(manager)
                %>
                </td>
              </tr>
			<%	
				i=i+1
				rs.MoveNext
			loop
			rs.Close
			%>
            </table>
         <%
			rs1.MoveNext
         loop
         rs1.Close
         %>   
            <table width="98%" border="0" cellspacing="0" cellpadding="0" align="center">
              <tr> 
                <td height="10"></td>
              </tr>
            </table>
            <table width="100%" border="0" cellspacing="0" cellpadding="0" align="center" bgcolor="<%=tablecolor%>">
              <tr bgcolor="<%=titlebgcolor%>"> 
                <td align="left" height=20>&nbsp;<img src="images/icon3.gif" width="16" height="16" align="absmiddle">&nbsp;<b><font color="<%=titlecolor%>">用户访问情况</font></b></td>
              </tr>
            </table>
            <table width="100%" border="0" cellspacing="0" cellpadding="0" align="center" bgcolor="<%=tablecolor%>">
              <tr bgcolor="#ffffff"> 
				<td height=30>
					&nbsp;您的真实IP:<%=Request.ServerVariables("Remote_HOST")%>
					&nbsp;操作系统:<%=Request.ServerVariables("Http_User_Agent")%>
				</td>
			  </tr>	            
            </table>
            <table width="100%" border="0" cellspacing="0" cellpadding="0" align="center" bgcolor="<%=tablecolor%>">
              <tr bgcolor="<%=titlebgcolor%>"> 
                <td align="left" height=20>&nbsp;<img src="images/icon3.gif" width="16" height="16" align="absmiddle">&nbsp;<b><font color="<%=titlecolor%>">在线用户情况</font></b></td>
              </tr>
            </table>
            <%
              sql="select count(keyno) from user_login where loginflag='1'"
			  rs.Open sql,cn,1,1
			  reccount2=rs(0)
			  rs.Close
              sql="select * from user_login order by logintime "
			  rs.Open sql,cn,1,1
			  colzs=8
			  if rs.RecordCount mod colzs=0 then
				rowzs=int(rs.RecordCount/colzs)
			 else
				rowzs=int(rs.RecordCount/colzs)+1
			 end if	
			 reccount=rs.RecordCount
			 
			 %> 
            <table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
              <tr bgcolor="#ffffff"> 
				<td height=30>
					&nbsp;目前共有 <b><%=reccount%></b> 人在线,其中注册用户 <b><%=reccount2%></b> 人,访客 <b><%=reccount-reccount2%></b> 人
				</td>
			  </tr>	            
              <tr bgcolor="#ffffff"> 
				<td height=30>
		            <table width="100%" border="0" cellspacing="1" cellpadding="0" align="center">
						<%
						for i=1 to rowzs
							Response.Write ("<tr>")
							for j=1 to colzs
								if not rs.EOF then
						%>
							<td width='12%'>&nbsp;&nbsp;
							<%if rs("loginflag")="1" then%>
								<a href="user_display.asp?userno=<%=rs("userno")%>" target=_blank><%=trim(rs("usercode"))%></a>
							<%else%>
								<a href="#" title="<%=trim(rs("ipaddress"))%>"><font color="666666">[游客]</font></a>
							<%end if%>	
							</td>
						<%
								 rs.MoveNext	
								else
									
							Response.Write("<td width='12%'>&nbsp;</td>")							 
								end if
							next
							Response.Write ("</tr>")
						next
						%>
					</table>
				</td>
			  </tr>	            
            </table>
            <table width="98%" border="0" cellspacing="0" cellpadding="0" align="center">
              <tr> 
                <td height="10"></td>
              </tr>
            </table>
			<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
				<tr> 
				  <td align="center" height="26"> 
					<table width="300" border="0" cellspacing="0" cellpadding="0" align="center">
					  <tr> 
						<td width="15"><img src="images/on.gif"></td>
						<td>&nbsp;有新的帖子</td>
						<td width=20></td>
						<td width="15" align="absmiddle"><img src="images/off.gif"></td>
						<td>&nbsp;没有新的帖子</td>
					  </tr>
					</table>
				  </td>
				</tr>
			</table>
          </td>
        </tr>
      </table>
    </td>
  </tr>
</table>

<!-- #include file="end.asp" -->
<!-- #include file="func.inc" -->

⌨️ 快捷键说明

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