news.asp

来自「超炫电台程序开发了两个版本了」· ASP 代码 · 共 64 行

ASP
64 行
字号
<!--#include file="config.asp"-->
<% dim Rs,TypeSQL,ActionName
  set Rs=server.createobject("adodb.recordset")
  select case Trim(Request("action"))	
        case else
        TypeSQL="SELECT top 6 "&CategoryName&"_SoftInfo.SoftID,"&CategoryName&"_SoftInfo.SoftName,"&CategoryName&"_SoftInfo.SoftVer,"&CategoryName&"_SoftInfo.CateID,"&CategoryName&"_SoftInfo.SubCateID,"&CategoryName&"_SoftInfo.AllHits,"&CategoryName&"_SoftInfo.LicenceType,"&CategoryName&"_SoftInfo.SoftTime,"&CategoryName&"_SubCate.SubCateName FROM "&CategoryName&"_SoftInfo,"&CategoryName&"_SubCate where "&CategoryName&"_SoftInfo.SubCateID="&CategoryName&"_SubCate.SubCateID order by "&CategoryName&"_SoftInfo.LicenceType desc,"&CategoryName&"_SoftInfo.SoftID desc"
		ActionName="全部歌曲"
        end select
	
%>
<HTML>
<HEAD>
<TITLE></TITLE>
<META http-equiv=Content-Type content='text/html; charset=gb2312'>
<link rel="stylesheet" type="text/css" href="style.css">
<BODY text=#003300 vLink=#002200 bgColor=#cccccc leftMargin=0 topMargin=0 onConTextMenu="event.returnValue=false">
<table cellspacing=0 cellpadding=0 width=100% align=center border=0>
  <tbody> 
  <tr> 
    <td valign="top" bgcolor="#FFFFFF"> 
      <table width="100%" border="0" cellpadding="3" cellspacing="1" bgcolor="#E3E3E3" background="../images/dot.gif">
        <tr align="center" bgcolor="#B5D331"> 
          <td height="10">歌曲名称</td>
          <td height="10">演唱者</td>
          <td height="10">人气</td>
          <td height="10">加入时间</td>
        <% 
	rs.open TypeSQL,conn,1,1 
	if not(rs.eof and rs.bof) then 
	do while not rs.eof
	Title=trim(rs("SoftName"))& " "& trim(rs("SoftVer"))
	%>
        <tr> 
          <td bgcolor="#FFFFFF"> 
            <%  response.write "[<A href=""SoftList.asp?CateID="&rs("CateID")&"&SubCateID="&rs("SubCateID")&""" class=""ArticleList"">"&trim(rs("SubCateName"))&"</a>] <A href=""SoftView.Asp?SoftID="&rs("SoftID")&""" title=""" & title & """ target=_parent class=""ArticleList"">" & title & "</a> " %>
          </td>
          <td align="center" nowrap bgcolor="#FFFFFF"><%=rs("LicenceType")%></td>
          <td align="center" nowrap bgcolor="#FFFFFF"> <%=rs("AllHits")%></td>
          <td align="center" bgcolor="#FFFFFF"> 
            <% if rs("SoftTime")=Date() then
			response.write "<font color=red>"&rs("SoftTime")&"</font>"
			else
			response.write rs("SoftTime")
			end if %>
          </td>
        </tr>
        <%
	rs.movenext 
    loop  
	end if
	rs.close
	 %>
      </table>
    </td>
  </tr>
  </tbody> 
</table>
</body>
</html>
<%
set rs=nothing
CloseDatabase
%>

⌨️ 快捷键说明

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