📄 right.asp
字号:
<%
if session("user_type")<>"T" then
response.redirect "../../index.asp"
end if
%>
<!--#INCLUDE FILE="../../system/odbc_connection.asp"-->
<html>
<head>
<title>重要公告</title>
<link rel="stylesheet" type="text/css" href="../../system/right.css">
</head>
<body topmargin="0" leftmargin="0" >
<center>
<p> 
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" width='90%'>
<tr align="center"><td><font color=#FFFFFF>重要公告</font></td></tr>
<tr>
<td height="110" valign="middle" style="background-color:#ffffff">
<ul>
<%
Dim sql,rs
sql="select top 3 title,id from news where type='TZ' order by id desc"
set rs=db.Execute(sql)
Do while not rs.Eof
%>
<li><a href="#" onClick="open('news/particular.ASP?id=<%=rs("id")%>','','resizable=0,scrollbars=1,status=no,toolbar=no,location=no,menu=no,width=500,height=300,left=150,top=150')"><%=rs("title")%></a></li>
<%
rs.MoveNext
Loop
%>
</ul>
<p align="left" >  <a href="news/index.asp" target=middle><<管理</a></p>
</td>
</tr>
</table>
<br>
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" width='90%'>
<tr align="center"><td><font color=#FFFFFF>作业提示</font></td></tr>
<tr>
<td style="background-color:#ffffff" height="110" valign="middle">
<ul>
<li>
<%
'函数,计算未批作业数,
private function count_not_look()
sql="select count(*) as temp_number from homework_answer,homework "
sql=sql + " where look_flag = 0 "
sql=sql + " and homework.homework_id=homework_answer.homework_id"
sql=sql + " and homework.homework_type='H'"
sql=sql + " and homework.lesson_id='" & session("lesson_id") & "'"
set rs2=db.execute(sql)
count_not_look = rs2("temp_number")
rs2.close
set rs2=nothing
end function
response.write "未批作业<b> " & count_not_look() & " </b>份"
Response.write "</li><li>"
'函数,计算未批准人数,
private function count_wait(lesson_id)
sql="select count(user_id) as temp_number from user_lesson where lesson_id = '" & session("lesson_id") & "'"
sql=sql & " and (user_type ='G' or user_type ='S')"
sql=sql & " and permit = 0"
set rs2=db.execute(sql)
count_wait = rs2("temp_number")
end function
response.write "<p>等待批准<b> " & count_wait("1001") & " </b>人"
%>
</li>
</ul>
</td>
</tr>
</table>
<br>
</center>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -