MyGroup.asp
上传用户:jisenq
上传日期:2014-06-29
资源大小:7216k
文件大小:10k
源码类别:

数据库编程

开发平台:

ASP/ASPX

  1. <% Option Explicit %>
  2. <!--#include file="../FS_Inc/Const.asp" -->
  3. <!--#include file="../FS_InterFace/MF_Function.asp" -->
  4. <!--#include file="../FS_Inc/Function.asp" -->
  5. <!--#include file="../FS_Inc/Func_Page.asp"-->
  6. <!--#include file="lib/strlib.asp" -->
  7. <!--#include file="lib/UserCheck.asp" -->
  8. <%
  9. Dim GroupRs,GroupID,GroupName,CroupContent,InfoType,ClassType,AddTime,GroupCreater,GroupManager,isSys,hits,GroupMembers,GroupMembersArray,TempRs,HotGroupNumber,ForwardNumber,ForIndex,GroupManagerArray
  10. Dim int_RPP,int_Start,int_showNumberLink_,str_nonLinkColor_,toF_,toP10_,toP1_,toN1_,toN10_,toL_,showMorePageGo_Type_,cPageNo,i
  11. '---------------------------------分页定义
  12. int_RPP=15 '设置每页显示数目
  13. int_showNumberLink_=8 '数字导航显示数目
  14. showMorePageGo_Type_ = 1 '是下拉菜单还是输入值跳转,当多次调用时只能选1
  15. str_nonLinkColor_="#999999" '非热链接颜色
  16. toF_="<font face=webdings title=""首页"">9</font>"   '首页 
  17. toP10_=" <font face=webdings title=""上十页"">7</font>" '上十
  18. toP1_=" <font face=webdings title=""上一页"">3</font>" '上一
  19. toN1_=" <font face=webdings title=""下一页"">4</font>" '下一
  20. toN10_=" <font face=webdings title=""下十页"">8</font>" '下十
  21. toL_="<font face=webdings title=""最后一页"">:</font>" '尾页
  22. '--------------------------------------------------
  23. Set GroupRs=Server.CreateObject(G_FS_RS)
  24. GroupRs.open "select gdID,title,content,InfoType,ClassType,AddTime,UserNumber,AdminName,ClassMember,isSys,hits from FS_ME_GroupDebateManage where UserNumber like '"&session("FS_Usernumber")&"'",User_Conn,1,3
  25. %>
  26. <html xmlns="http://www.w3.org/1999/xhtml">
  27. <title>User Manage Center-网站内容管理系统</title>
  28. <meta name="keywords" content="风讯cms,cms,FoosunCMS,FoosunOA,FoosunVif,vif,风讯网站内容管理系统">
  29. <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
  30. <meta content="MSHTML 6.00.3790.2491" name="GENERATOR" />
  31. <link href="images/skin/Css_<%=Request.Cookies("FoosunUserCookies")("UserLogin_Style_Num")%>/<%=Request.Cookies("FoosunUserCookies")("UserLogin_Style_Num")%>.css" rel="stylesheet" type="text/css">
  32. <head></head>
  33. <body> 
  34. <table width="98%" border="0" align="center" cellpadding="1" cellspacing="1" class="table"> 
  35.   <tr> 
  36.     <td> <!--#include file="top.asp" --> </td> 
  37.   </tr> 
  38. </table> 
  39. <table width="98%" height="135" border="0" align="center" cellpadding="1" cellspacing="1" class="table"> 
  40.   <tr class="back"> 
  41.     <td   colspan="2" class="xingmu" height="26"> <!--#include file="Top_navi.asp" --> </td> 
  42.   </tr> 
  43.   <tr class="back"> 
  44.     <td width="18%" valign="top" class="hback"> <div align="left"> 
  45.         <!--#include file="menu.asp" --> 
  46.       </div></td> 
  47.     <td width="82%" valign="top" class="hback"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0"> 
  48.         <tr> 
  49.           <td width="72%"  valign="top"> <table width="98%" height="112" border="0" align="center" cellpadding="3" cellspacing="1" class="table"> 
  50.               <tr class="xingmu"> 
  51.                 <td height="33">&nbsp;&nbsp;&nbsp;
  52. <a href='#'>创建社群</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  53. <a href='myGroup.asp?userNumber=<%=session("FS_UserNumber")%>'>我的社群</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  54. <a href='Group.asp'>社群首页</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  55. <a href='#'>社群帮助</a>
  56. </td> 
  57.               </tr>
  58.               <%
  59. If Not GroupRs.eof then
  60. '分页使用-----------------------------------
  61. GroupRs.PageSize=int_RPP
  62. cPageNo=NoSqlHack(Request.QueryString("page"))
  63. If cPageNo="" Then cPageNo = 1
  64. If not isnumeric(cPageNo) Then cPageNo = 1
  65. cPageNo = Clng(cPageNo)
  66. If cPageNo<=0 Then cPageNo=1
  67. If cPageNo>GroupRs.PageCount Then cPageNo=GroupRs.PageCount 
  68. GroupRs.AbsolutePage=cPageNo
  69. End if
  70. for i=0 to int_RPP
  71. if GroupRs.eof then exit for
  72. '-------------------------------------
  73. GroupID=GroupRs("gdID")
  74. GroupName=GroupRs("title")
  75. CroupContent=GroupRs("content")
  76. InfoType=GroupRs("InfoType")
  77. ClassType=GroupRs("ClassType")
  78. AddTime=GroupRs("AddTime")
  79. GroupCreater=GroupRs("UserNumber")
  80. GroupManager=GroupRs("AdminName")
  81. isSys=GroupRs("isSys")
  82. hits=GroupRs("hits")
  83. GroupMembers=GroupRs("ClassMember")
  84. '----------------------获得管理员------------------
  85. GroupManagerArray=split(GroupManager,",")
  86. GroupManager=""
  87. for ForIndex=0 to ubound(GroupManagerArray)
  88. Set TempRs=User_Conn.execute("Select UserName from FS_ME_Users where UserNumber='"&GroupManagerArray(ForIndex)&"'")
  89. if not TempRs.eof then
  90. GroupManager=GroupManager&","&TempRs("UserName")
  91. end if
  92. next
  93. GroupManager=DelHeadAndEndDot(GroupManager)
  94. '-------------获得创建人-------------------------------
  95. if isSys=1 then
  96. GroupCreater="管理员"
  97. else
  98. Set TempRs=User_Conn.execute("Select UserName from FS_ME_Users where UserNumber='"&GroupCreater&"'")
  99. if not TempRs.eof then
  100. GroupCreater=TempRs("UserName")
  101. end if
  102. end if
  103. '-----------------获得社群所属行业----------------------
  104. Set TempRs=User_Conn.execute("select vClassName from FS_ME_VocationClass where vcid="&ClassType)
  105. if not TempRs.eof then
  106. ClassType=TempRs("vClassName")
  107. else
  108. ClassType="其他"
  109. end if
  110. '-----------------获得社群成员数----------------------
  111. if GroupMembers<>"" then
  112. GroupMembersArray=split(GroupMembers,",")
  113. end if
  114. '------------------------------------------
  115. Response.Write("<tr><td>")
  116. Response.Write("<table width='100%' height='60' border='0' cellpadding='1' cellspacing='1' class='table'>"&vbcrlf)
  117. Response.Write("<tr class='xingmu'><td colspan=10><a href='Group_unit.asp?GDID="&GroupID&"'><img src=""images/GroupUser.gif"" border=""0""/><strong> "&GroupName&"</strong></a></td></tr>"&vbcrlf)
  118. Response.Write("<tr height='20'>"&vbcrlf)
  119. Response.Write("<td align='center' class='hback'>现有成员</td>"&vbcrlf)
  120. Response.Write("<td class='hback' align='center' width='20%'>创建时间</td>"&vbcrlf)
  121. Response.Write("<td class='hback' align='center' width='12%'>创建人</td>"&vbcrlf)
  122. Response.Write("<td class='hback' align='center'>管理员</td>"&vbcrlf)
  123. Response.Write("<td class='hback' align='center'>所属行业</td>"&vbcrlf)
  124. Response.Write("</tr>"&vbcrlf)
  125. Response.Write("<tr>"&vbcrlf)
  126. if instr(GroupMembers,",")>0 then
  127. Response.Write("<td align='center' class='hback'>"&Ubound(GroupMembersArray)&"人</td>"&vbcrlf)
  128. else
  129. Response.Write("<td align='center' class='hback'>0人</td>"&vbcrlf)
  130. end if
  131. Response.Write("<td class='hback' align='center' width='20%'>"&Datevalue(AddTime)&"</td>"&vbcrlf)
  132. Response.Write("<td class='hback' align='center' width='12%'>"&GroupCreater&"</td>"&vbcrlf)
  133. Response.Write("<td class='hback' align='center'>"&GroupManager&"</td>"&vbcrlf)
  134. Response.Write("<td class='hback' align='center'>"&ClassType&"</td>"&vbcrlf)
  135. Response.Write("</tr>"&vbcrlf)
  136. Response.Write("<tr height='40'>"&vbcrlf)
  137. Response.Write("<td class='hback' colspan=5><img src=""images/GroupNews.gif""/>"&CroupContent&"</td>"&vbcrlf)
  138. Response.Write("</tr>"&vbcrlf)
  139. Response.Write("</table>")
  140. Response.Write("</td></tr>")
  141. GroupRs.movenext
  142. next
  143.   %>
  144.   <%
  145. Response.Write("<tr>"&vbcrlf)
  146. Response.Write("<td align='right' colspan='5'  class=""hback"">"&fPageCount(GroupRs,int_showNumberLink_,str_nonLinkColor_,toF_,toP10_,toP1_,toN1_,toN10_,toL_,showMorePageGo_Type_,cPageNo)&"</td>"&vbcrlf)
  147. Response.Write("</tr>"&vbcrlf)
  148. %>
  149.             </table></td> 
  150.           <td width="32%" valign="top"> <table width="98%"  border="0" align="center" cellpadding="1" cellspacing="1" class="table"> 
  151.               <tr> 
  152.                 <td height="27" class="xingmu"><span class="bigtitle"><strong>·热门社群</strong></span></td> 
  153.               </tr> 
  154. <%
  155. HotGroupNumber=5
  156. Set TempRs=User_Conn.execute("Select gdID,title from FS_ME_GroupDebateManage order by hits desc")
  157. for ForIndex=0 to HotGroupNumber
  158. if TempRs.eof then exit for
  159. Response.Write("<tr class='hback'>"&vbcrlf)
  160. Response.Write("<td  valign='top' align='left' height='20'>&nbsp;"&ForIndex+1&".<a href='Group_unit.asp?GDID="&TempRs("gdID")&"'>"&TempRs("title")&"</a></td>"&vbcrlf)
  161. Response.Write("</tr>"&vbcrlf)
  162. TempRs.movenext
  163. next
  164. %>
  165.             </table> 
  166.             <table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table"> 
  167.               <tr> 
  168.                 <td width="50%" height="27"  class="xingmu"><span class="bigtitle"><strong>·社群排行</strong></span></td> 
  169.               </tr> 
  170.   <%
  171. ForwardNumber=5
  172. Set TempRs=User_Conn.execute("Select gdID,title from FS_ME_GroupDebateManage order by ClassMemberNum desc")
  173. for ForIndex=0 to ForwardNumber
  174. if TempRs.eof then exit for
  175. Response.Write("<tr class='hback'>"&vbcrlf)
  176. Response.Write("<td  valign='top' align='left' height='20'>&nbsp;"&ForIndex+1&".<a href='Group_unit.asp?GDID="&TempRs("gdID")&"'>"&TempRs("title")&"</a></td>"&vbcrlf)
  177. Response.Write("</tr>"&vbcrlf)
  178. TempRs.movenext
  179. next
  180.   %>
  181.             </table> 
  182.             <table width="98%" height="124" border="0" align="center" cellpadding="3" cellspacing="1" class="table"> 
  183.               <tr> 
  184.                 <td width="50%" height="27"  class="xingmu"><span class="bigtitle"><strong>·社群分类</strong></span></td> 
  185.               </tr> 
  186.               <tr> 
  187.                 <td height="94" valign="top" class="hback">新闻,下载,商品,房产,供求,求职,招聘,其它 </td> 
  188.               </tr> 
  189.             </table></td> 
  190.         </tr> 
  191.       </table></td> 
  192.   </tr> 
  193.   <tr class="back"> 
  194.     <td height="20"  colspan="2" class="xingmu"> <div align="left"> 
  195.         <!--#include file="Copyright.asp" --> 
  196.       </div></td> 
  197.   </tr> 
  198. </table> 
  199. </body>
  200. </html>
  201. <%
  202. Set GroupRs=nothing
  203. Set User_Conn=nothing
  204. Set TempRs=nothing
  205. Set Fs_User = Nothing
  206. %>
  207. <!--Powsered by Foosun Inc.,Product:FoosunCMS V4.0系列-->