<!--#include file="htm_top.asp"-->
<%
filename=request("fp")
SqlStr=request("SqlStr")
FormNum=request("FormNum")
if SqlStr="" then
	response.write SqlStr&"为空？？？"
        Response.End 
end if
if FormNum<>"" then
body="document.write(""<form name='"&FormNum&"' onSubmit='return ting()' target='tingmp3' action='/play/playl.asp'>"");"&vbNewLine
body=body&"document.write(""<table width='250' border='0' align='left' cellpadding='0' cellspacing='0'>"");"&vbNewLine

set rs=conn.execute(SqlStr)
    if rs.eof and rs.bof then 
	response.write "暂无推荐专集"
        Response.End 
        else
for i=1 to pagemax
if not rs.eof then
body=body&"document.write(""<tr><td width='250' height='23' class='line4'>"");"&vbNewLine
body=body&"document.write(""<table border='0' cellspacing='0' cellpadding='0'><TBODY><tr>"");"&vbNewLine
body=body&"document.write(""<td width='20' align='center'><font color='#636563'>"&i&".</font></td>"");"&vbNewLine
body=body&"document.write(""<td width='22'><INPUT type='checkbox' value='"&rs("musicid")&"' name='ID'></td> "");"&vbNewLine
body=body&"document.write(""<td width='205'>[<a href='/singer/"&rs("nclassid")&".Htm'>"&left(rs("nclass"),5)&"</a>] <a href='/play/play.asp?id="&rs("musicid")&"&.Htm'>"&left(rs("name"),8)&"</a> "");"&vbNewLine
body=body&"document.write(""</td></tr></TBODY></TABLE></td>"");"&vbNewLine
rs.movenext
end if
next

end if
rs.close
set rs=nothing
conn.close
set conn=nothing
body=body&"document.write(""<tr><td height='25' colspan='2'>"");"&vbNewLine
body=body&"document.write(""<table width='250' height='25' border='0' align='right' cellpadding='0' cellspacing='0'><TBODY><tr>"");"&vbNewLine
body=body&"document.write(""<td width='80'><div align='center'><img name='chkOthers' onClick='CheckAll("&FormNum&")' src='/images/index_qx.gif' width='52' height='20' border='0' style='cursor:hand'></td>"");"&vbNewLine
body=body&"document.write(""<td width='80'><div align='center'><img name='chkOthers' onClick='CheckOthers("&FormNum&")' src='images/index_fx.gif' width='52' height='20' border='0' style='cursor:hand'></td>"");"&vbNewLine
body=body&"document.write(""<td width='100'><div align='center'><input type='image' src='images/index_pl.gif' width='79' height='20' border='0'></td>"");"&vbNewLine
body=body&"document.write(""</tr></TBODY></TABLE></td></tr></table></form>"");"&vbNewLine
else
body="document.write(""<div align='center'>"");"&vbNewLine
body=body&"document.write(""<table border='0' width='395' cellpadding='0' style='border-collapse: collapse' height='120'>"");"&vbNewLine
body=body&"document.write(""<tr><td height='5' colspan='2'></td><tr>"");"&vbNewLine
set rs=conn.execute(SqlStr)
    if rs.eof and rs.bof then 
	response.write "暂无点歌"
        Response.End 
        else
for i=1 to 7
if not rs.eof then
body=body&"document.write(""<tr>"");"&vbNewLine
for j = 1 to 2
if not rs.eof then
body=body&"document.write(""<td width='197' height='20'>．<a target=blank href=qqdg/qqshow.asp?id="&rs("id")&" title='『"&rs("fromuser")&"』点一首<"&rs("musicname")&">送给『"&rs("foruser")&"』'>"&left(rs("fromuser"),4)&" 点<font color=red>"&left(rs("musicname"),5)&"</font>送 "&left(rs("foruser"),3)&"</td>"");"&vbNewLine
rs.movenext
         end if
          next
body=body&"document.write(""</tr>"");"&vbNewLine
rs.movenext
end if
next
end if
rs.close
set rs=nothing
conn.close
set conn=nothing
body=body&"document.write(""</table></div>"")"&vbNewLine
end if
Set fso = Server.CreateObject("Scripting.FileSystemObject")
Set fout = fso.CreateTextFile(server.mappath(FILENAME))
fout.Write body
fout.close
%>
<html>

<head><title>生成首页js文件</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<style>
td{font-size:9pt;line-height:140%} 
body{font-size:9pt;line-height:140%} 
a:link       { color: #0033CC; text-decoration: none }
a:visited    { color: #0033CC; text-decoration: none }
a:active     { color: #FF0000; text-decoration: none }
a:hover      { color: #000000; text-decoration: underline}
</style>
</head>
<body topmargin="1" leftmargin="1" scroll="no">
<table border="0" cellspacing="0" style="border-collapse: collapse" width="100%" cellpadding="0">
  <tr>
    <td width="100%"><font color="#FF0000">·</font>成功生成JS,时间<%=Now()%><br><font color="#FF0000">·</font><a target="_blank" href="<%=filename%>"><%=filename%></a></td>
  </tr>
</table>
</body>    
</html>