?? news_type.asp
字號:
<!--#include file="conn.asp"-->
<html>
<head>
<script language="javascript">
<!--
function jc(lb)
{
if(lb=="")
{alert('對不起!信息不能為空!');
return false;}
window.location="news_type.asp?cz=tj&lb="+lb;}
function xg(gn,id)
{if(gn=="")
{alert('對不起!不能為空!');
return false;}
window.location="news_type.asp?cz=xg&lb="+gn+"&id="+id;}
-->
</script>
<link rel="stylesheet" href="style.css" ="text/css">
<title>分類管理</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>
<%id=request.querystring("id")
lb= request.querystring("lb")
cz=request.querystring("cz")%>
<body>
<div align="left">
<table width="778" border="1" cellspacing="0" cellpadding="0" bgcolor="#7894AF" align="center">
<tr bgcolor="#eeeeee">
<td height="25" ><%=why%> 歡迎來到 <%=bb%>!<%
RESPONSE.Write "CM提醒你---你來訪的時間是: " & YEAR(date()) & "年" & MONTH(date()) & "月" & DAY(date()) & "日"
%> <a href="news_admin.asp">返 回</a></td>
</tr>
</table>
<%if id<>"" and cz="sc" then
exec="delete * from type where id="+id
conn.execute exec
conn.close
response.redirect "news_type.asp"
end if
if lb<>"" and cz="tj" then
lb=xrzh(lb)
exec="insert into type (lx) values ('"+lb+"')"
conn.execute exec
conn.close
response.redirect "news_type.asp"
end if
if lb<>"" and cz="xg" then
lb=xrzh(lb)
exec="update type set lx='"+lb+"' where id="+id
conn.execute exec
conn.close
response.redirect "news_type.asp"
end if
exec="select * from type order by id desc"
set rs=server.createobject("adodb.recordset")
rs.open exec,conn,1,1%>
<table width="400" border="0" cellpadding="0" cellspacing="1" align="center">
<tr bgcolor="#CCD8E6" height="25">
<td align="center">類別名稱</td>
<td align="center">處理</td>
</tr>
<%j=1
do while not rs.eof%>
<tr bgcolor="#E3E9F1" height="25">
<td align="center"><input type="text" name="lb<%=j%>" value="<%=rs("lx")%>"></td>
<td align="center">
<a href=# onClick="javascript:xg(lb<%=j%>.value,'<%=rs("id")%>');">修改</a>
|
<a href="news_type.asp?id=<%=rs("id")%>&cz=sc" onClick="javascript:return confirm('確實要刪除該記錄嗎?');">刪除</a>
</td>
</tr>
<%j=j+1
rs.movenext
loop%>
<tr bgcolor="#CCD8E6">
<td align="center"><input ="text" name="lb<%=j+1%>"></td>
<td align="center" colspan="2"><a href=# onclick="javascript:jc(lb<%=j+1%>.value);">添加</td>
</tr>
</table>
<p>
<%rs.close
conn.close
set conn=nothing%>
</p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p> </p>
<p align="center">Copyright 2006-2008 http://cm86.vicp.net All Rights Reserved </p>
<p align="center"><font color="#E3E9F1" size="6" face="華文行楷">CM 新 聞 發 布 系 統 V 1。0</font> </p>
<p align="center"> </p>
</div>
</body>
</htm>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -