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

📄 config_forum.asp

📁 漂亮的企业网站系统v11 1、整体修改了上一版的一些BUG。 2、修改了页面底部的统计形式。 3、修改了“公告更新”栏目
💻 ASP
📖 第 1 页 / 共 4 页
字号:
  'on error resume next

  set rs=conn.execute("select username,birthday from [user_data]")
    do while not rs.eof
      if rs(1)="" then
        rs.movenext
      elseif month(rs(1))<>month(now()) or day(rs(1))<>day(now()) then 
        rs.movenext
      else
        if isdate(rs(1)) then 
          age=datediff("yyyy",rs(1),Now())
          birthday=birthday & "<a href=user_view.asp?username="&rs(0)&" title=祝"&age&"岁生日快乐! target=_blank> 〖祝 <font class=blue><b>"&rs(0)&"</b></font> 生日快乐  <img src=images/small/birthday.gif align=absmiddle border=0>〗</a>"
          birthnum=birthnum+1
        end if 
        rs.movenext
      end if 
    loop
  rs.close
  if birthnum=0 then
    birthday="<font color=#FF0000>※今天没有会员过生日※</font>"
  end if 
  set rs=nothing
  temp1=forum_table1&"<tr"& forum_table2&"><td>&nbsp;"&img_small("fk4")&" <font class=end><b>今天过生日的会员(共 "&birthnum&" 人)</b></font></td></tr>" & _
  vbcrlf&"<tr"& format_table(3,1)&"><td align=center height=30>"&birthday&"</td></tr>" & _
  vbcrlf&"</table>"
  response.write temp1&kong
end sub

'联盟论坛开始
sub links_main(lt,nummer)
  dim temp1,nname
  temp1=forum_table1&"<tr"& forum_table2&"><td>&nbsp;"&img_small("fk4")&" <font class=end><b>联盟论坛</b></font></td></tr>" & _
  vbcrlf&"<tr"& format_table(3,1)&"><td align=center><table border=0 width='100%' cellspacing=0 cellpadding=0>"
  sql="select * from links where sort='"&lt&"' and hidden=1 order by orders"
  set rs=conn.execute(sql)
  do while not rs.eof
    temp1=temp1&vbcrlf&"<tr align=center height=40>"
    for i=1 to nummer
      if rs.eof then exit for
      temp1=temp1&vbcrlf&"<td width='16%'><a href='"&rs("url")&"' target=_blank>"
      if lt="txt" then
        temp1=temp1&code_html(rs("nname"),1,0)
      else
        temp1=temp1&"<img src='"&rs("pic")&"' border=0 width=88 height=31 title='"&code_html(rs("nname"),1,0)&"'>"
      end if
      temp1=temp1&"</a></td>"
      rs.movenext
    next
    temp1=temp1&vbcrlf&"</tr>"
  loop
  rs.close
  temp1=temp1&"</table></td></tr></table>"
  response.write temp1&kong
end sub
'友情论坛结束

'------------------------------------forum_list-------------------------------------
sub forum_view()
dim pelpic:pelpic=ispel
dim goodpic:goodpic=isgood
dim hotpic:hotpic=re_counter
dim newpic:newpic=now()-tim
if pelpic=1 then
pelpic="&nbsp;&nbsp;<img src=images/small/tuijian.gif border=0 title=推荐帖不想看看么?>"
else
pelpic=""
end if
if goodpic=1 then
goodpic="&nbsp;&nbsp;<img src=images/small/jinghua.gif border=0 title=精华帖不想看看么?>"
else
goodpic=""
end if
if hotpic>2 then
hotpic="&nbsp;&nbsp;<img src=images/small/hot.gif width=26 height=10 border=0 title=热帖不想看看么?>"
else
hotpic=""
end if
if newpic<1 then
newpic="&nbsp;&nbsp;<img src=images/small/new_xin.gif width=28 height=14 border=0 title=新帖不想瞧瞧么?> "
else
newpic=""
end if
  select case int(istop)
  case 1
    folder_type="istop"
  case 2
    folder_type="istops"
  case else
  if int(ispel)=1 then
      folder_type="ispel"
     else
    if int(isgood)=1 then
      folder_type="isgood"
    else
      if int(islock)=1 then
        folder_type="islock"
      else
        if int(re_counter)>=10 then
          folder_type="ishot"
        elseif int(isvote)=1 then
          folder_type="isvote"
        end if
      end if
    end if
   end if
  end select

  view_url="forum_view.asp?forum_id="&forumnid&"&view_id="&id
  if int(re_counter)>0 then
    topic_head="<img loaded=no src='images/small/fk_plus.gif' border=0 id=followImg"&id&" style=""cursor:hand;"" onclick=""load_tree("&forumnid&","&id&")"" title='展开贴子列表'>"
  else
    topic_head="<img src='images/small/fk_minus.gif' border=0 id=followImg"&id&">"
  end if

  response.write vbcrlf&"<tr align=center"&format_table(3,1)&mtr&">" & _
     vbcrlf&"<td bgcolor="&web_var(web_color,5)&"><img src='images/"&web_var(web_config,5)&"/"&folder_type&".gif' border=0></td>" & _
     vbcrlf&"<td bgcolor="&web_var(web_color,5)&">"
  if action="manage" then
    response.write "<input type=checkbox name=del_id value='"&id&"' class=bg_3>"
  else
    response.write "<img src='images/icon/"&icon&".gif' border=0>"
  end if


'论坛主题加色和加粗开始  
  if color<>"" then
  color="<a href='"&view_url&"'><font title='贴子主题:"&code_html(topic,1,0)&"<br>发贴时间:"&tim&"<br>最后回复:"&re_username&"<br>回复时间:"&re_tim&"' color="&color&">"
  else
  color="<a href='"&view_url&"' title='贴子主题:"&code_html(topic,1,0)&"<br>发贴时间:"&tim&"<br>最后回复:"&re_username&"<br>回复时间:"&re_tim&"'>"
  end if
  if bb=true then
    bb="<b>"
  else
    bb=""
  end if
'论坛主题加色和加粗结束

  response.write "</td>" & _
  		 vbcrlf&"<td align=left>"&topic_head&bb&color&code_html(topic,0,22)&"</font></a></b>&nbsp;"&index_pagecute(view_url,re_counter+1,web_var(web_num,3),"#cc3300")&newpic&goodpic&hotpic&pelpic&"</td>" & _
  		 vbcrlf&"<td>"&format_user_view(username,1,"")&"</td>" & _
  		 vbcrlf&"<td><a href='"&view_url&"' target=_blank><img src='images/small/new_win.gif' alt='打开新窗口浏览此贴' border=0 width=13 height=11></a></td>"
'论坛主题加色和加粗变量替换相关代码(注意上面的bb&color),至此本文件修改完毕。
         if int(isvote)=1 then
            response.write "<td>共<font class=red>"&poll_counter&"</font>票</td>"
         else 
            response.write "<td>"&re_counter&"<font class=gray>/</font>"&counter&"</td>"
         end if
  response.write "<td align=left><font class=timtd>"&time_type(re_tim,6)&"</font><font class=red>│</font>"&format_user_view(re_username,1,"")&"</td>" & _
  		 vbcrlf&"</tr>" & _
  		 vbcrlf&"<tr"&format_table(3,1)&" style=""display:none"" id=follow"&id&" height=30><td colspan=2>&nbsp;</td><td colspan=6 id=followTd"&id&" style=""padding:0px""><div style=""width:240px;margin-left:18px;border:1px solid black;background-color:"&web_var(web_color,5)&";color:"&web_var(web_color,7)&";padding:2px"" onclick=""load_tree("&forumnid&","&id&")"">正在读取关于本主题的跟贴,请稍侯……</div></td></tr>"
  del_temp=del_temp+1
end sub


'------------------------------------forum_view-------------------------------------
function view_type()
  dim uf,kd
  dim up:up=int(popedom_format(u_popedom,42))
  table_bg=format_table(3,1)
  if ii mod 2=0 then table_bg=forum_table3
  if var_null(u_whe)<>"" then
    u_whe="来自:"&u_whe&"<br>"
  end if
  if var_null(u_nname)<>"" then
    u_nname="头衔:"&u_nname&"<br>"
  end if
   if len(u_face)<4 then 
     kd=""
     uf="images/face/"&u_face&".gif'"
  else 
     uf=""&u_face&""
     kd="width=120 height=120"
  end if

  view_type=vbcrlf & "<tr align=center valign=top"&table_bg&"><td width='20%'>" & _
	    vbcrlf & "<table border=0 width='98%'><tr><td align=center height=30><table border=0><tr><td width=100 align=center><font class=blue><b>"&u_username&"</b></font></td><td>&nbsp;"&user_view_sex(u_sex)&"</td></tr></table></td></tr>" & _
	    vbcrlf & "<tr><td align=center height=96>"
   if rs("u_faceurl")="" or isnull(rs("u_faceurl")) then 	    
      view_type=view_type&vbcrlf &"<img src='images/face/"&rs("u_face")&".gif' border=0></td></tr>"
    else 
     view_type=view_type&vbcrlf &"<img border=0 src='"&rs("u_faceurl")&"' width='"&rs("u_facewidth")&"' height='"&rs("u_faceheight")&"'></td></tr>"
   end if
      view_type=view_type&vbcrlf & "<tr><td height=15><img src='images/star/star_"&user_star(u_integral,u_power,1)&".gif' border=0></td></tr>" & _
	    vbcrlf & "<tr><td>等级:"&user_view_power(u_power,0)&user_star(u_bbs_counter,u_power,2)&"<br>威望:<font color=red>+"&u_userpower&"&nbsp;&nbsp;[荣誉]</font><br>人气:"&u_renqi&"<br> "&u_nname& "贴子:"&u_bbs_counter&"<br>积分:"&u_integral&"<br>"&money_name&":"&u_emoney&"<br>魅力:"&u_usercp&"<br>"&u_whe&"注册:"&formatdatetime(rs("u_tim"),2)&"</td></tr>" & _
	    vbcrlf & "</table></td><td width='80%' height='100%'>" & _
	    vbcrlf & "<table border=0 width='99%' cellspacing=2 cellpadding=0 height='100%'><tr height=25><td width='85%'>" & _
	    vbcrlf & "<a target=_blank href='user_view.asp?username="&server.urlencode(u_username)&"'><img src='images/"&web_var(web_config,5)&"/forum_profile.gif' title='查看 "&u_username&" 的详细信息' border=0></a>&nbsp;" & _
	    vbcrlf & "<a target=_blank href='user_friend.asp?action=add&add_username="&server.urlencode(u_username)&"'><img src='images/"&web_var(web_config,5)&"/forum_friend.gif' title='将 "&u_username&" 加为我的好友' border=0></a>&nbsp;" & _
	    vbcrlf & "<a target=_blank href='user_message.asp?action=write&accept_uaername="&server.urlencode(u_username)&"'><img src='images/"&web_var(web_config,5)&"/forum_message.gif' title='给 "&u_username&" 发短信' border=0></a>&nbsp;"
	    if forumreadonly=0 then
 view_type=view_type&vbcrlf&"<a href='forum_edit.asp?forum_id="&forumid&"&edit_id="&qid&"'><img src='images/"&web_var(web_config,5)&"/forum_edit.gif' title='编辑这个贴子' border=0></a>&nbsp;"
    if int(fir_islock)<>1 then
      view_type=view_type&vbcrlf&"<a href='forum_reply.asp?forum_id="&forumid&"&quote=yes&view_id="&qid&"'><img src='images/"&web_var(web_config,5)&"/forum_quote.gif' title='引用并回复这个贴子' border=0></a>&nbsp;" & _
         vbcrlf&"<a href='forum_reply.asp?forum_id="&forumid&"&view_id="&qid&"'><img src='images/"&web_var(web_config,5)&"/forum_reply.gif' title='回复这个贴子' border=0></a>"
    else
      view_type=view_type&vbcrlf&"<img src='images/small/forum_reply.gif' title='该贴已被锁定' border=0>"
    end if
	if login_mode="admin" or login_mode="super" then
view_type=view_type&vbcrlf & "  <a href='forum_view.asp?forum_id="&forumid&"&view_id="&id&"' onclick=window.open('super_point.asp?userna="&server.urlencode(u_username)&"','add','toolbar=no,location=no,status=no,width=400,height=380')><img src='images/small/forum_point.gif' title='管理员、版主奖惩用户专用' border=0></a>"
end if
  else
    if format_user_power(login_username,login_mode,forumpower)="yes" then
 view_type=view_type&vbcrlf&"<a href='forum_edit.asp?forum_id="&forumid&"&edit_id="&qid&"'><img src='images/"&web_var(web_config,5)&"/forum_edit.gif' title='编辑这个贴子' border=0></a>"
 end if
  end if
    view_type=view_type&"</td><td width='15%' align=right>第 <font class=red_3><b>"&ii+(viewpage-1)*nummer&"</b></font> 楼</td></tr>" & _
     vbcrlf & "<tr><td colspan=2 height=1 bgcolor="&web_var(web_color,3)&"></td></tr>"
	    
  if up=0 then
    view_type=view_type&vbcrlf & "<tr><td colspan=2 valign=top align=center>" & _
	      vbcrlf & "<table border=0 width='98%' class=tf><tr><td height=30>" & _
	      vbcrlf & "<img src='images/icon/"&rs("icon")&".gif' align=absMiddle border=0>&nbsp;<marquee align='middle' width='96%' height='6%' behavior='alternate'><font class=red_3><b>"&code_html(rs("topic"),1,0)&"</b></font></marquee></td></tr>" & _
	      vbcrlf & "<tr><td class=bw><font class=htd>"
          if rs("isvote")=1 then 
	         view_type=view_type & code_jk(rs("word")) & FormatPoll(iid)  & "</font></td></tr>"
	      else
	         view_type=view_type & code_jk(rs("word")) & "</font></td></tr>"
	      end if
	      view_type=view_type & "</table></td></tr>"
    if rs("edited")<>"" then
    view_type=view_type& "<tr><td colspan=2 height=20 align=right><br><font  color='#000066'>["&rs("edited")&"]</font> </td></tr>"
    end if
    	      view_type=view_type&"<tr><td colspan=2 height=20 align=right><font color=#808080>…━╋┫ 本图片及文字资料版权归<B> <font color=blue>"&u_username&"</font>&nbsp;和&nbsp;<font color=blue>流真岁月</font></B>&nbsp;共同所有,未经同意请勿转载 ┣╋━…</font></br><font color=#808080>…━╋┫ <a href='http://www.anxina.net'>『流真岁月』</a>非常感谢<B>&nbsp;<font color=red>"&u_username&"</font>&nbsp;</B>的支持与参与 ┣╋━…</font><br>"&img_small("signature")&"</td></tr>" & _
              vbcrlf & "<tr><td colspan=2 height=30 align=center valign=top><table border=0 width='96%' class=tf><tr><td class=bw><font class=htd>"&u_remark&"</font></a></td></tr></table></td></tr>"
  else
    view_type=view_type&vbcrlf & "<tr><td colspan=2 valign=top><br><table border=0><tr><td class=htd><font class=red_2>========================<br>&nbsp;&nbsp;该用户的论坛发言已暂时被管理屏蔽!<br>========================</font></td></tr></table></td></tr>"
  end if
  view_type=view_type&vbcrlf & "</table><tr align=center valign=top"&table_bg&"><td height=18><table border=0 cellspacing=2 cellpadding=0 height=18 class=tf><tr><td height=18>"&img_small("forum_tim")&"<font class=gray>"&time_type(rs("tim"),8)&"</font></td></tr>" &_
     vbcrlf & "</table></td><td><table width='98%' border=0 cellspacing=2 cellpadding=0 height=18 class=tf><tr><td width='45%' height=18><SCRIPT language=javascript src=ads/text.js></SCRIPT></td>" &_
     vbcrlf & "<td width='35%' align=right>"&ip_types(rs("ip"),u_username,1)&" <img src='images/small/sys.gif' align=absMiddle title='"&view_sys(rs("sys"))&"' border=0> <a href=""javascript:"&del_type&"('"&forumid&"','"&iid&"');""><img src='images/small/forum_del.gif' align=absMiddle border=0></a></td></tr>" &_
     vbcrlf & "</table></td></tr>"
end function

function user_view_sex(us)
dim sql8,rs8
    sql8="select * from user_login where l_username='"&u_username&"'"
  set rs8=conn.execute(sql8)
    if rs8.eof then

⌨️ 快捷键说明

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