www.gusucode.com > 漂亮的地方旅游景点景观介绍网站源代码 > admin/down/downlevel.asp

    <!--#include file="../config.asp" -->
<!--#include file="../../inc/page.asp" -->
<% 
call zwtj()
call chkqx(13,7)
mytit=mytit&"<a href=""Jw_downlevel.asp"">软件级别管理</a> > "

select case action
case "show",""
mytit=mytit&"软件级别列表"
call show()
case "doup"
call doup()
end select

'显示
sub show()
sql="select * from Jw_downlevel order by id asc"
call record(rs,sql,1)
call head()
%>
<link href="../inc/mm.css" rel="stylesheet" type="text/css" />
<table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#116BAE">
<tr>
<td bgcolor="#FFFFFF"><table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#FFFFFF">
<tr>
<td id="tit"><%= mytit %></td>
</tr>
<tr>
<td>
<table width="100%" border="0" cellpadding="2" cellspacing="1" bgcolor="#FFFFFF">
<tr>
<td width="5%" height="18" align="center" bgcolor="#C5E0F3"><strong>ID</strong></td>
<td width="35%" bgcolor="#C5E0F3"><strong>软件级别</strong></td>
<td width="42%" align="center" bgcolor="#C5E0F3"><strong>图片</strong></td>
<td width="18%" align="center" bgcolor="#C5E0F3">&nbsp;</td>
</tr>
<% 
dim i,sz
sz=20
i=sz
dim bgc
%>
<div style="display:none"><% call fenpage(sz,rs,10) %></div>
<%
do while not rs.eof and i>0 
if i mod 2=0 then 
bgc="#D2E9FF"
else
bgc="#D2E1EE"
end if
%>
<form name="form1" id="form1" method="post" action="?action=doup&amp;id=<%= rs("id") %>">
<tr id="r<%=rs("id")%>" bgcolor=<%= bgc %> onMouseOver="museing(r<%=rs("id")%>,0,'<%= bgc %>')" onMouseOut="museing(r<%=rs("id")%>,1,'<%= bgc %>')">
<td align="center"><%= rs("id") %></td>
<td><input name="mc" type="text" class="inp" value="<%= rs("mc") %>" readonly onfocus="this.className='focus'" onblur="this.className='inp'"/></td>
<td align="center"><img src="<%= rs("pic") %>" /></td>
<td align="center"><input name="Submit" type="submit" class="button_1" value="更新" onmouseover="this.className='button_2'" onmouseout="this.className='button_1'"/></td>
</tr>
</form>
<% 
i=i-1
rs.movenext 
loop
%>
<tr>
<td colspan="4" bgcolor="#C5E0F3">&nbsp;</td>
</tr>
</table></td>
</tr>
</table></td>
</tr>
</table>
<%
call recordend(rs)
call connend()
call foot()
end sub

sub doup()
dim mc,xyjf,hykj
mc=Trim(Request.Form("mc"))
hykj=Trim(Request.Form("hykj"))

conn.begintrans'事务开始
'更新记录
conn.execute("update Jw_downlevel set mc='"&mc&"' where id="&id)
if conn.errors.count>0 then ''有错误发生 
conn.rollbacktrans''回滚 
end if
conn.CommitTrans ''提交事务
call connend()
response.Redirect("Jw_downlevel.asp")
end sub
%>