<!--#include file="../inc/jc_conn.asp"-->
<!--#include file="../inc/const.asp"-->
<%
dim id,rs,act
id=SafeRequest("id")
act=Request("act")
set rs=server.createobject("adodb.recordset")
if act="down" then
sql="select * from musiclist where musicid in ("&id&")"
rs.open sql,conn,1,1
if rs.eof then
response.Write("<script>alert('对不起，数据库中没有这首歌！')</script>")
else
lrc=rs("lrc")
end if
rs.close
Response.ContentType = "*.lrc" 
Rw lrc
response.end
elseif act="add" or act="edit" then
sql="select * from musiclist where musicid in ("&id&")"
rs.open sql,conn,1,1
if rs.eof then
response.Write("<script>alert('对不起，数据库中没有这首歌！')</script>")
else
lrc=rs("lrc")
name=rs("name")
nclass=rs("nclass")
end if
rs.close

%><html>
<head>
<title>添加LRC歌词：<%=name%>-<%=nclass%></title>
<style type="text/css">
A{text-decoration:none;color:black}
A:hover {COLOR: #ff0000; TEXT-DECORATION: underline}
body{  font-size: 75%; font-family:"Verdana", "Arial", "宋体"; }
 td{font-size:9pt;}
INPUT.buttonface{BACKGROUND: #000000; border:1px solid black; COLOR: #ffffff; FONT-SIZE: 9pt; FONT-STYLE: normal; FONT-VARIANT: normal; FONT-WEIGHT: normal; HEIGHT: 18px; LINE-HEIGHT: normal}
input.smallInput{border:1px solid black;FONT-SIZE: 9pt; FONT-STYLE: normal; FONT-VARIANT: normal; FONT-WEIGHT: normal; HEIGHT: 18px; LINE-HEIGHT: normal}
</style>
</head>
<body leftmargin="0" topmargin="0">
<form name=form action="?act=save&id=<%=id%>"  method="POST">
<div align="center">
  <center>
<table border="0" width="260" cellspacing="0" cellpadding="0" bgcolor="">
  <tr>
    <td width=184 height=20 align="center" bgcolor=""><font color="">歌曲名称：</font><%=name%></td>
    <td width=213 height=20 align="center" bgcolor=""><font color="">所属歌手：</font><%=nclass%></td>
  </tr>
  <tr>
    <td colspan=2 align="center" width="399">LRC歌词内容</td>
  </tr>
  <tr>
    <td colspan=2 width="399">
      <p align="center"><TEXTAREA name=songwords rows=18 cols=36 style="font-family: 宋体"><%=lrc%></TEXTAREA></p>
    </td>
  </tr>
    <tr>
          <td width="399" height="25" colspan=2> <p>添加人: 
              <input name="username" type="text" id="username" value="您的网名" size="15">
              <br>QQ号码:<input name="qq" type="text" id="qq" value="您的qq" size="10">
            </p>
    </td>
  </tr>
  <tr><input name="musicname" type="hidden" value="<%=name%>">
    <td colspan=2 height=20 align=center width="399"><input type=submit name=submit value="添 加"> <input type=reset name=reset value="清 除">  
      <p></p>  
      
    </td>  
  </tr>  
</table>  
  </center>
</div>
</form>  
  
</body>  
  
</html>  
<%
elseif act="save" then
if len(request.form("songwords"))>20 then
sql="select * from addlrc"
rs.open sql,conn,1,3
rs.addnew
rs("lrc")=request.form("songwords")
rs("musicid")=id
rs("username")=request.form("username")
rs("qq")=request.form("qq")
rs("musicname")=request.form("musicname")
rs.update
rs.close
response.Write("<script>alert('谢谢"&request.form("username")&"对本站是支持\n\n歌词需审核后才能显示');window.close();</script>")
else
response.Write("<script>alert('LRC歌词内容???');window.close();</script>")
end if
else
end if
set rs=nothing
%>