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

数据库编程

开发平台:

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="../lib/strlib.asp" -->
  6. <!--#include file="../lib/UserCheck.asp" -->
  7. <!--#include file="../../FS_Inc/Func_Page.asp" -->
  8. <%
  9. '获得留言
  10. dim book_rs,new_count
  11. set book_rs= Server.CreateObject(G_FS_RS)
  12. book_rs.open "Select count(BookID) From FS_ME_Book where M_ReadUserNumber='"&Fs_User.UserNumber&"' and M_ReadTF=0 and M_Type=2",User_Conn,1,3
  13.  if book_rs(0)>0 then
  14.  new_count = "<span class=""tx""><b>您有新留言"& book_rs(0) &"</b></span>"
  15.  else
  16.  new_count =  book_rs(0)
  17.  end if
  18. book_rs.close:set book_rs = nothing
  19. if Request("Action")="del" then
  20. if trim(replace(Request("id")," ",""))="" then
  21. strShowErr = "<li>请至少选择一项</li>"
  22. Response.Redirect(""& s_savepath &"/lib/error.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl=")
  23. Response.end
  24. end if
  25. Conn.execute("Delete from FS_SD_News where id in ("& replace(Request("id")," ","") &") and UserNumber='"& Fs_User.UserNumber &"'")
  26. strShowErr = "<li>删除成功</li>"
  27. Response.Redirect(""& s_savepath &"/lib/success.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl="& s_savepath &"/supply/PublicManage.asp")
  28. Response.end
  29. end if
  30. if NoSqlHack(Request.QueryString("Refresh"))="1" then
  31. dim u_rs
  32. set u_rs= Server.CreateObject(G_FS_RS)
  33. u_rs.open "select EditTime,id from FS_SD_News where id="& NoSqlHack(Request.QueryString("id")) &" and UserNumber='"& Fs_User.UserNumber &"'",Conn,1,3
  34. u_rs("EditTime")=now
  35. u_rs.update
  36. u_rs.close:set u_rs=nothing
  37. strShowErr = "<li>重发成功</li>"
  38. Response.Redirect(""& s_savepath &"/lib/success.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl="& s_savepath &"/supply/PublicManage.asp")
  39. Response.end
  40. end if
  41. if NoSqlHack(Request("UserLock"))="1" then
  42. if trim(replace(Request("id")," ",""))="" then
  43. strShowErr = "<li>请至少选择一项</li>"
  44. Response.Redirect(""& s_savepath &"/lib/error.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl=")
  45. Response.end
  46. end if
  47. Conn.execute("Update FS_SD_News set islock=1 where id in ("& replace(Request("id")," ","") &") and UserNumber='"& Fs_User.UserNumber &"'")
  48. strShowErr = "<li>撤消成功</li>"
  49. Response.Redirect(""& s_savepath &"/lib/success.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl="& s_savepath &"/supply/PublicManage.asp")
  50. Response.end
  51. end if
  52. if NoSqlHack(Request("UserLock"))="0" then
  53. if trim(replace(Request("id")," ",""))="" then
  54. strShowErr = "<li>请至少选择一项</li>"
  55. Response.Redirect(""& s_savepath &"/lib/error.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl=")
  56. Response.end
  57. end if
  58. Conn.execute("Update FS_SD_News set islock=0 where id in ("& replace(Request("id")," ","") &") and UserNumber='"& Fs_User.UserNumber &"'")
  59. strShowErr = "<li>提交成功,等待审核</li>"
  60. Response.Redirect(""& s_savepath &"/lib/success.asp?ErrCodes="&Server.URLEncode(strShowErr)&"&ErrorUrl="& s_savepath &"/supply/PublicManage.asp")
  61. Response.end
  62. end if
  63. Dim int_RPP,int_Start,int_showNumberLink_,str_nonLinkColor_,toF_,toP10_,toP1_,toN1_,toN10_,toL_,showMorePageGo_Type_,cPageNo,strpage,rs,i
  64. int_RPP=20 '设置每页显示数目
  65. int_showNumberLink_=8 '数字导航显示数目
  66. showMorePageGo_Type_ = 1 '是下拉菜单还是输入值跳转,当多次调用时只能选1
  67. str_nonLinkColor_="#999999" '非热链接颜色
  68. toF_="<font face=webdings title=""首页"">9</font>"   '首页 
  69. toP10_=" <font face=webdings title=""上十页"">7</font>" '上十
  70. toP1_=" <font face=webdings title=""上一页"">3</font>" '上一
  71. toN1_=" <font face=webdings title=""下一页"">4</font>" '下一
  72. toN10_=" <font face=webdings title=""下十页"">8</font>" '下十
  73. toL_="<font face=webdings title=""最后一页"">:</font>"
  74. dim tmp_lock,tmp_valite,tmp_uselock,tmp_valite_1,para_rs,g_tmp
  75. set para_rs=Conn.execute("select top 1 warnTime from FS_SD_Config")
  76. if para_rs.eof then
  77. response.Write("找不到供求配置信息")
  78. response.end
  79. set para_rs=nothing
  80. else
  81. g_tmp=para_rs(0)
  82. if request.QueryString("usvalite")="1" then
  83. tmp_valite_1 =  " and (datevalue(editTime)+ValidTime)-datevalue(now)<="&para_rs(0)&" and (datevalue(editTime)+ValidTime)>=datevalue(now)"
  84. else
  85. tmp_valite_1=""
  86. end if
  87. set para_rs=nothing
  88. end if
  89. strpage=request("page")
  90. 'if len(strpage)=0 Or strpage<1 or trim(strpage)=""Then:strpage="1":end if
  91. %>
  92. <html xmlns="http://www.w3.org/1999/xhtml">
  93. <title>User Manage Center-网站内容管理系统</title>
  94. <meta name="keywords" content="风讯cms,cms,FoosunCMS,FoosunOA,FoosunVif,vif,风讯网站内容管理系统">
  95. <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
  96. <meta content="MSHTML 6.00.3790.2491" name="GENERATOR" />
  97. <link href="../images/skin/Css_<%=Request.Cookies("FoosunUserCookies")("UserLogin_Style_Num")%>/<%=Request.Cookies("FoosunUserCookies")("UserLogin_Style_Num")%>.css" rel="stylesheet" type="text/css">
  98. <head>
  99. </head>
  100. <body>
  101. <table width="98%" border="0" align="center" cellpadding="1" cellspacing="1" class="table">
  102.   <tr>
  103.     <td>
  104.       <!--#include file="../top.asp" -->
  105.     </td>
  106.   </tr>
  107. </table>
  108. <table width="98%" height="135" border="0" align="center" cellpadding="1" cellspacing="1" class="table">
  109.     <tr class="back"> 
  110.       <td   colspan="2" class="xingmu" height="26"> <!--#include file="../Top_navi.asp" -->
  111.     </td>
  112.     </tr>
  113.     <tr class="back"> 
  114.       <td width="18%" valign="top" class="hback"> <div align="left"> 
  115.           <!--#include file="../menu.asp" -->
  116.         </div></td>
  117.       <td width="82%" valign="top" class="hback">
  118.   <table width="98%" border="0" align="center" cellpadding="5" cellspacing="1" class="table">
  119.         <tr class="hback"> 
  120.           <td  valign="top">你的位置:<a href="../../">网站首页</a> &gt;&gt; <a href="../main.asp">会员首页</a> 
  121.             &gt;&gt; <a href="PublicManage.asp">供求系统</a> &gt;&gt; 供求信息管理</td>
  122.         </tr>
  123.         <tr class="hback"> 
  124.           <td  valign="top"><a href="PublicSupply.asp">发布信息</a>┆<a href="PublicManage.asp">管理信息</a>┆<a href="PublicManage.asp#top10">你的信息浏览排行(TOP10)</a>┆<a href="PublicManage.asp#new">最新供求信息</a>┆<a href="PublicManage.asp#rec">供求推荐</a>┆<a href="../Book.asp?M_type=2">我的新留言(<%=new_count%>)</a></td>
  125.         </tr>
  126.       </table>
  127.      
  128.         
  129.       <table width="98%" border="0" align="center" cellpadding="5" cellspacing="1" class="table">
  130.         <tr class="hback">
  131.           <td width="10%"><span class="tx">强烈推荐</span></td> 
  132.           <td width="90%">
  133.   <a href=" " id="printWord" ></a><%
  134.    dim i_loop
  135. set rs= Server.CreateObject(G_FS_RS)
  136. if G_IS_SQL_DB=0 Then
  137. rs.open "select  top 6 ID,PubTitle,PubType,Addtime,hits,PubAddress,EditTime,UserNumber From FS_SD_News where isLock=0 and isPass=1 and (datevalue(editTime)+ValidTime)>datevalue(now) and OrderID=2 order by EditTime desc,id desc",Conn,1,3
  138. Else
  139. rs.open "select  top 6 ID,PubTitle,PubType,Addtime,hits,PubAddress,EditTime,UserNumber From FS_SD_News where isLock=0 and isPass=1 and convert(nvarchar(10),editTime+ValidTime,120)>convert(nvarchar(10),getDate(),120) and OrderID=2 order by EditTime desc,id desc",Conn,1,3
  140. End if
  141. if rs.eof then
  142. response.Write("<span class=""tx"">没推荐信息</span>")
  143. else
  144. i_loop=0
  145.   %>
  146.   <script language="JavaScript">
  147. var PublicTime = 3500; 
  148. var TextTime = 20; 
  149. var infoi = 0;
  150. var txti = 0;
  151. var txttimer;
  152. var infotimer;
  153. var publictitle = new Array(); 
  154. var publichref = new Array(); 
  155. <%do while not rs.eof %>
  156. publictitle[<%=i_loop%>] = "<%=Fs_User.GetFriendName(rs("UserNumber"))%>:<%=rs("PubTitle")%>[<%=rs("EditTime")%>]";
  157. publichref[<%=i_loop%>] = "../../Supply/Supply.asp?id=<%=rs("id")%>";
  158. <%rs.movenext%>
  159. <%i_loop=i_loop+1%>
  160. <%loop%>
  161. <%rs.close:set rs=nothing%>
  162. function showinfo()
  163. {
  164. var endstr = "_"
  165. hwinfotr = publictitle[infoi];
  166. infolink = publichref[infoi];
  167. if(txti==(hwinfotr.length-1)){endstr="";}
  168. if(txti>=hwinfotr.length){
  169. clearInterval(txttimer);
  170. clearInterval(infotimer);
  171. infoi++;
  172. if(infoi>=publictitle.length){
  173. infoi = 0
  174. }
  175. infotimer = setInterval("showinfo()",PublicTime);
  176. txti = 0;
  177. return;
  178. }
  179. clearInterval(txttimer);
  180. document.getElementById("printWord").href=infolink;
  181. document.getElementById("printWord").innerHTML = hwinfotr.substring(0,txti+1)+endstr;
  182. txti++;
  183. txttimer = setInterval("showinfo()",TextTime);
  184. }
  185. showinfo();
  186. </script>
  187. <%end if%>
  188.   </td>
  189.         </tr>
  190.       </table>
  191.       <table width="98%" border="0" align="center" cellpadding="5" cellspacing="1" class="table">
  192.         <form name="myForm" method="post" action="">
  193.           <tr> 
  194.             <td height="23" colspan="8" class="hback_1"><a href="PublicManage.asp">全部信息</a>┆<a href="PublicManage.asp?islock=0">已审核</a>┆<a href="PublicManage.asp?islock=1">未审核</a>┆<a href="PublicManage.asp?User_lock=1">用户锁定</a>┆<a href="PublicManage.asp?User_lock=0">用户未锁定</a>┆<a href="PublicManage.asp?valite=1">过期信息</a>┆<a href="PublicManage.asp?usvalite=1" title="有效期小于<%=g_tmp%>天的信息">即将过期的信息</a></td>
  195.           </tr>
  196.           <tr> 
  197.             <td width="4%" class="hback_1"><div align="center"> 
  198.                 <input name="chkall" type="checkbox" id="chkall" onClick="CheckAll(this.form);" value="checkbox" title="点击选择所有或者撤消所有选择">
  199.               </div></td>
  200.             <td width="27%" class="hback_1"><div align="center"><strong>标题</strong></div></td>
  201.             <td width="13%" class="hback_1"><div align="center"><strong>收录专栏</strong></div></td>
  202.             <td width="11%" class="hback_1"><div align="center"><strong>到期时间</strong></div></td>
  203.             <td width="21%" class="hback_1"><div align="center"><strong>操作</strong></div></td>
  204.             <td width="8%" class="hback_1"><div align="center"><strong>审核结果</strong></div></td>
  205.             <td width="8%" class="hback_1"><strong>用户锁定</strong></td>
  206.             <td width="8%" class="hback_1"><div align="center"><strong>点击</strong></div></td>
  207.           </tr>
  208.           <%
  209.    if Request.QueryString("islock")="0" then
  210. tmp_lock=" and ispass=1"
  211. elseif Request.QueryString("islock")="1" then
  212. tmp_lock=" and ispass=0"
  213. else
  214. tmp_lock=""
  215. end if
  216. if Request.QueryString("User_lock")="1" then
  217. tmp_uselock = " and islock=1"
  218. elseif Request.QueryString("User_lock")="0" then
  219. tmp_uselock = " and islock=0"
  220. else
  221. tmp_uselock = " "
  222. end if
  223. if Request.QueryString("valite")="1" then
  224. tmp_valite = " and (datevalue(editTime)+ValidTime)<datevalue(now)"
  225. else
  226. tmp_valite = " "
  227. end if
  228. set rs = Server.CreateObject(G_FS_RS)
  229. rs.open "select id,PubTitle,EditTime,ValidTime,ispass,islock,hits,MyClassID from FS_SD_News where UserNumber='"& Fs_User.UserNumber&"' " &tmp_lock & tmp_valite & tmp_uselock& tmp_valite_1 &" order by EditTime desc,OrderID desc,id desc",Conn,1,3
  230. if rs.eof then
  231.    rs.close
  232.    set rs=nothing
  233.    Response.Write"<tr  class=""hback""><td colspan=""8""  class=""hback"" height=""40"">没有记录。</td></tr>"
  234. else
  235. rs.PageSize=int_RPP
  236. cPageNo=NoSqlHack(Request.QueryString("Page"))
  237. If cPageNo="" Then cPageNo = 1
  238. If not isnumeric(cPageNo) Then cPageNo = 1
  239. cPageNo = Clng(cPageNo)
  240. If cPageNo<=0 Then cPageNo=1
  241. If cPageNo>rs.PageCount Then cPageNo=rs.PageCount 
  242. rs.AbsolutePage=cPageNo
  243. for i=1 to rs.pagesize
  244. if rs.eof Then exit For 
  245.   %>
  246.           <tr  onMouseOver=overColor(this) onMouseOut=outColor(this)>
  247.             <td class="hback"><input name="id" type="checkbox" id="id" value="<%=rs("id")%>"></td>
  248.             <td class="hback"><a href="<% = Replace("/"&G_VIRTUAL_ROOT_DIR&"/" ,"//","/")%>Supply/Supply.asp?id=<%=rs("id")%>" target="_blank"><%=rs("PubTitle")%></a></td>
  249.             <td class="hback"><div align="center"> 
  250.                 <%
  251. dim rs_z
  252. set rs_z = User_Conn.execute("select ClassID,ClassCName From FS_ME_InfoClass where ClassID="& rs("MyClassID")&" and UserNumber='"&Fs_User.UserNumber&"'")
  253. if rs_z.eof then
  254. response.Write "--"
  255. else
  256. Response.Write "<a href=../ShowInfoClass.asp?ClassID="& rs_z("Classid")&"&UserNumber="& Fs_User.UserNumber &">" &rs_z("ClassCName")&"</a>"
  257. end if
  258. %>
  259.               </div></td>
  260.             <td class="hback"><div align="center"><%=datevalue(rs("EditTime"))+rs("ValidTime")%></div></td>
  261.             <td class="hback"><div align="center"><a href="PublicSupplyEdit.asp?id=<%=rs("id")%>&Action=edit">修改</a> 
  262.                 <a href="PublicManage.asp?id=<%=rs("id")%>&Refresh=1">重发</a> 
  263.                 <a href="PublicSupplyEdit.asp?id=<%=rs("id")%>&Action=Copy">复制</a> 
  264.                 <%if rs("islock")=0 then%>
  265.                 <a href="PublicManage.asp?id=<%=rs("id")%>&UserLock=1"  onClick="{if(confirm('确定要撤消吗?n撤消后前台将不能显示')){return true;}return false;}">撤消</a> 
  266.                 <%else%>
  267.                 <a href="PublicManage.asp?id=<%=rs("id")%>&UserLock=0"  onClick="{if(confirm('确定要撤消吗?n撤消后前台将不能显示')){return true;}return false;}">提交</a> 
  268.                 <%end if%>
  269.                 <a href="PublicManage.asp?id=<%=rs("id")%>&Action=del"  onClick="{if(confirm('确定要删除吗?')){return true;}return false;}">删除</a> 
  270.               </div></td>
  271.             <td class="hback"><div align="center"> 
  272.                 <%if rs("ispass")=1 then:response.Write"已审核":else:Response.Write"<span class=""tx"">未审核</span>":end if%>
  273.               </div></td>
  274.             <td class="hback"><div align="center"> 
  275.                 <%if rs("islock")=1 then:response.Write("<span class=""tx"">已撤消</span>"):else:Response.Write("未锁定"):end if%>
  276.               </div></td>
  277.             <td class="hback"><div align="center"><%=rs("hits")%></div></td>
  278.           </tr>
  279.           <%
  280.   rs.movenext
  281.   next
  282.   %>
  283.           <tr  class="hback"> 
  284.             <td colspan="8"><div align="right"> 
  285.                 <%
  286. response.Write "<p>"&  fPageCount(rs,int_showNumberLink_,str_nonLinkColor_,toF_,toP10_,toP1_,toN1_,toN10_,toL_,showMorePageGo_Type_,cPageNo)
  287. %>
  288.                 <input name="Action" type="hidden" id="Action">
  289.                 <input name="UserLock" type="hidden" id="UserLock">
  290.                 <input type="button" name="Submit" value="删除"  onClick="document.myForm.Action.value='del';{if(confirm('确定清除您所选择的记录吗?')){this.document.myForm.submit();return true;}return false;}">
  291.                 <input type="button" name="Submit2" value="撤消信息"  onClick="document.myForm.UserLock.value='1';{if(confirm('确定撤消信息吗?n撤消后将不能显示')){this.document.myForm.submit();return true;}return false;}">
  292.                 <input type="button" name="Submit3" value="提交信息"  onClick="document.myForm.UserLock.value='0';{if(confirm('确定重新提交信息吗?')){this.document.myForm.submit();return true;}return false;}">
  293.               </div></td>
  294.           </tr>
  295.           <% 
  296.   rs.close:set rs=nothing
  297.   end if
  298.   %>
  299.         </form>
  300.       </table>
  301.       <a name="top10"></a>
  302. <table width="98%" border="0" align="center" cellpadding="5" cellspacing="1" class="table">
  303.         <tr> 
  304.           <td colspan="5" class="xingmu"> 
  305.             <table width="98%" border="0" cellspacing="0" cellpadding="0">
  306.               <tr>
  307.                 <td width="2%" valign="top"><strong><img src="../Images/folderclosed.gif" width="16" height="16"></strong></td>
  308.                 <td width="98%" valign="bottom" class="xingmu"><strong>你的信息被浏览排行前10名</strong> 
  309.                 </td>
  310.               </tr>
  311.             </table></td>
  312.         </tr>
  313.         <tr> 
  314.           <td width="9%" class="hback_1"><div align="center"><strong>类型</strong></div></td>
  315.           <td width="33%" class="hback_1"><div align="center"><strong>标题</strong></div></td>
  316.           <td width="23%" class="hback_1"><div align="center"><strong>发布日期</strong></div></td>
  317.           <td width="18%" class="hback_1"><div align="center"><strong>到期日期</strong></div></td>
  318.           <td width="17%" class="hback_1"><div align="center"><strong>点击</strong></div></td>
  319.         </tr>
  320.         <%
  321. set rs= Server.CreateObject(G_FS_RS)
  322. rs.open "select  top 10 ID,PubTitle,PubType,Addtime,ValidTime,EditTime,hits,UserNumber From FS_SD_News where UserNumber='"& Fs_User.UserNumber &"' order by hits desc,id desc",Conn,1,3
  323. do while not rs.eof 
  324. %>
  325.         <tr onMouseOver=overColor(this) onMouseOut=outColor(this)>
  326.           <td class="hback"> <div align="center"> 
  327.               <%
  328.   select Case rs("PubType")
  329.    case 0
  330. response.Write("供应")
  331. case 1
  332. response.Write("<span class=""tx"">求购</span>")
  333. case 2
  334. response.Write("合作")
  335. case 3
  336. response.Write("代理")
  337. case else
  338. Response.Write("其他")
  339.  end select
  340.   %>
  341.             </div></td>
  342.           <td class="hback"><div align="left"><a href="<% = Replace("/"&G_VIRTUAL_ROOT_DIR&"/" ,"//","/")%>Supply/Supply.asp?id=<%=rs("id")%>" target="_blank"><%=rs("PubTitle")%></a></div></td>
  343.           <td class="hback"><div align="center"><%=rs("Addtime")%></div></td>
  344.           <td class="hback"><div align="center"><%=datevalue(rs("EditTime"))+rs("ValidTime")%></div></td>
  345.           <td class="hback"><div align="center"><a href=ShowUser.asp?UserNumber=<%=rs("UserNumber")%> target="_blank"><%=rs("hits")%></a></div></td>
  346.         </tr>
  347.         <%
  348. rs.movenext
  349. loop
  350. rs.close:set rs=nothing
  351. %>
  352.       </table>
  353.       <a name="new"></a> <table width="98%" border="0" align="center" cellpadding="5" cellspacing="1" class="table">
  354.         <tr> 
  355.           <td colspan="5" class="xingmu"> 
  356.             <table width="98%" border="0" cellspacing="0" cellpadding="0">
  357.               <tr> 
  358.                 <td width="2%" valign="top"><strong><img src="../Images/folderclosed.gif" width="16" height="16"></strong></td>
  359.                 <td width="98%" valign="bottom"  class="xingmu"><strong>最新供求信息20条</strong></td>
  360.               </tr>
  361.             </table></td>
  362.         </tr>
  363.         <tr> 
  364.           <td width="9%" class="hback_1"><div align="center"><strong>类型</strong></div></td>
  365.           <td width="33%" class="hback_1"><div align="center"><strong>标题</strong></div></td>
  366.           <td width="23%" class="hback_1"><div align="center"><strong>发布日期</strong></div></td>
  367.           <td width="18%" class="hback_1"><div align="center"><strong>地区</strong></div></td>
  368.           <td width="17%" class="hback_1"><div align="center"><strong>发布人</strong></div></td>
  369.         </tr>
  370.         <%
  371. set rs= Server.CreateObject(G_FS_RS)
  372. if G_IS_SQL_DB=0 Then
  373. rs.open "select  top 20 ID,PubTitle,PubType,Addtime,hits,PubAddress,UserNumber From FS_SD_News where isLock=0 and isPass=1 and (datevalue(editTime)+ValidTime)>datevalue(now) order by EditTime desc,id desc",Conn,1,3
  374. Else
  375. rs.open "select  top 20 ID,PubTitle,PubType,Addtime,hits,PubAddress,UserNumber From FS_SD_News where isLock=0 and isPass=1 and convert(nvarchar(10),editTime+ValidTime,120)>convert(nvarchar(10),getDate(),120) order by EditTime desc,id desc",Conn,1,3
  376. End if
  377. do while not rs.eof 
  378. %>
  379.         <tr onMouseOver=overColor(this) onMouseOut=outColor(this)>
  380.           <td class="hback"> <div align="center"> 
  381.               <%
  382.   select Case rs("PubType")
  383.    case 0
  384. response.Write("供应")
  385. case 1
  386. response.Write("<span class=""tx"">求购</span>")
  387. case 2
  388. response.Write("合作")
  389. case 3
  390. response.Write("代理")
  391. case else
  392. Response.Write("其他")
  393.  end select
  394.   %>
  395.             </div></td>
  396.           <td class="hback"><div align="left"><a href="<% = Replace("/"&G_VIRTUAL_ROOT_DIR&"/" ,"//","/")%>Supply/Supply.asp?id=<%=rs("id")%>" target="_blank"><%=rs("PubTitle")%></a></div></td>
  397.           <td class="hback"><div align="center"><%=rs("Addtime")%></div></td>
  398.           <td class="hback"><div align="center"><%=rs("PubAddress")%></div></td>
  399.           <%if rs("UserNumber")="0" then%>
  400.           <td class="hback"><div align="center">管理员</div></td>
  401.           <%else%>
  402.           <td class="hback"><div align="center"><a href=ShowUser.asp?UserNumber=<%=rs("UserNumber")%> target="_blank"><%=Fs_User.GetFriendName(rs("UserNumber"))%></a></div></td>
  403.           <%end if%>
  404.         </tr>
  405.         <%
  406. rs.movenext
  407. loop
  408. rs.close:set rs=nothing
  409. %>
  410.       </table>
  411.       <a name="rec" id="rec"></a> 
  412.       <table width="98%" border="0" align="center" cellpadding="5" cellspacing="1" class="table">
  413.         <tr> 
  414.           <td colspan="5" class="xingmu"> 
  415.             <table width="98%" border="0" cellspacing="0" cellpadding="0">
  416.               <tr> 
  417.                 <td width="2%" valign="top"><strong><img src="../Images/folderclosed.gif" width="16" height="16"></strong></td>
  418.                 <td width="98%" valign="bottom" class="xingmu"><strong>最新推荐信息20条</strong></td>
  419.               </tr>
  420.             </table></td>
  421.         </tr>
  422.         <tr> 
  423.           <td width="9%" class="hback_1"><div align="center"><strong>类型</strong></div></td>
  424.           <td width="33%" class="hback_1"><div align="center"><strong>标题</strong></div></td>
  425.           <td width="23%" class="hback_1"><div align="center"><strong>发布日期</strong></div></td>
  426.           <td width="18%" class="hback_1"><div align="center"><strong>地区</strong></div></td>
  427.           <td width="17%" class="hback_1"><div align="center"><strong>发布人</strong></div></td>
  428.         </tr>
  429.         <%
  430. set rs= Server.CreateObject(G_FS_RS)
  431. if G_IS_SQL_DB=0 Then
  432. rs.open "select  top 20 ID,PubTitle,PubType,Addtime,hits,PubAddress,UserNumber From FS_SD_News where isLock=0 and isPass=1 and (datevalue(editTime)+ValidTime)>datevalue(now) and OrderID=1 order by EditTime desc,id desc",Conn,1,3
  433. Else
  434. rs.open "select  top 20 ID,PubTitle,PubType,Addtime,hits,PubAddress,UserNumber From FS_SD_News where isLock=0 and isPass=1 and convert(nvarchar(10),editTime+ValidTime,120)>convert(nvarchar(10),getDate(),120) and OrderID=1 order by EditTime desc,id desc",Conn,1,3
  435. End if
  436. do while not rs.eof 
  437. %>
  438.         <tr onMouseOver=overColor(this) onMouseOut=outColor(this)>
  439.           <td class="hback"> <div align="center"> 
  440.               <%
  441.   select Case rs("PubType")
  442.    case 0
  443. response.Write("供应")
  444. case 1
  445. response.Write("<span class=""tx"">求购</span>")
  446. case 2
  447. response.Write("合作")
  448. case 3
  449. response.Write("代理")
  450. case else
  451. Response.Write("其他")
  452.  end select
  453.   %>
  454.             </div></td>
  455.           <td class="hback"><div align="left"><a href="<% = Replace("/"&G_VIRTUAL_ROOT_DIR&"/" ,"//","/")%>Supply/Supply.asp?id=<%=rs("id")%>" target="_blank"><%=rs("PubTitle")%></a></div></td>
  456.           <td class="hback"><div align="center"><%=rs("Addtime")%></div></td>
  457.           <td class="hback"><div align="center"><%=rs("PubAddress")%></div></td>
  458.           <%if rs("UserNumber")="0" then%>
  459.           <td class="hback"><div align="center">管理员</div></td>
  460.           <%else%>
  461.           <td class="hback"><div align="center"><a href=ShowUser.asp?UserNumber=<%=rs("UserNumber")%> target="_blank"><%=Fs_User.GetFriendName(rs("UserNumber"))%></a></div></td>
  462.           <%end if%>
  463.         </tr>
  464.         <%
  465. rs.movenext
  466. loop
  467. rs.close:set rs=nothing
  468. %>
  469.       </table></td>
  470.     </tr>
  471.     <tr class="back"> 
  472.       <td height="20"  colspan="2" class="xingmu"> <div align="left"> 
  473.           <!--#include file="../Copyright.asp" -->
  474.         </div></td>
  475.     </tr>
  476. </table>
  477. </body>
  478. </html>
  479. <script language="JavaScript" type="text/JavaScript">
  480. function CheckAll(form)  
  481.   {  
  482.   for (var i=0;i<form.elements.length;i++)  
  483.     {  
  484.     var e = myForm.elements[i];  
  485.     if (e.name != 'chkall')  
  486.        e.checked = myForm.chkall.checked;  
  487.     }  
  488. }
  489. </script>
  490. <%
  491. Set Fs_User = Nothing
  492. %>
  493. <!--Powsered by Foosun Inc.,Product:FoosunCMS V4.0系列-->