?? index.asp
字號:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file="Connections/yu.asp" -->
<%
Dim Recordset1
Dim Recordset1_numRows
Set Recordset1 = Server.CreateObject("ADODB.Recordset")
Recordset1.ActiveConnection = MM_yu_STRING
Recordset1.Source = "SELECT * FROM bs.room"
Recordset1.CursorType = 0
Recordset1.CursorLocation = 2
Recordset1.LockType = 1
Recordset1.Open()
Recordset1_numRows = 0
%>
<%
Dim Repeat1__numRows
Dim Repeat1__index
Repeat1__numRows = -1
Repeat1__index = 0
Recordset1_numRows = Recordset1_numRows + Repeat1__numRows
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>客房管理系統</title>
<style type="text/css">
<!--
body,td,th {
font-family: 新宋體;
}
body {
background-image: url(bg.gif);
}
.STYLE1 {
font-size: x-large;
color: #993333;
}
-->
</style></head>
<body>
<div align="center">客房管理系統</div>
<table border="1" cellpadding="0" cellspacing="0" width="100%" bordercolorlight="#416327" bordercolordark="#DEEBD6" height="13">
<tr>
<td bgcolor="#398A00" align="center" height="19">客房號</td>
<td bgcolor="#398A00" align="center" height="19">床位數</td>
<td bgcolor="#398A00" align="center" height="19">電視</td>
<td bgcolor="#398A00" align="center" height="19">空調</td>
<td bgcolor="#398A00" align="center" height="19">價格</td>
<td bgcolor="#398A00" align="center" height="19">房間狀態</td>
<td bgcolor="#398A00" align="center" height="19">備注</td>
<td bgcolor="#398A00" align="center">預訂</td>
</tr>
<% While ((Repeat1__numRows <> 0) AND (NOT Recordset1.EOF)) %>
<tr valign="middle">
<td height="1" nowrap="nowrap"><%=(Recordset1.Fields.Item("roomno").Value)%></td>
<td height="1" nowrap="nowrap"><%=(Recordset1.Fields.Item("bednum").Value)%></td>
<td height="1" nowrap="nowrap">
<%select case Recordset1.Fields.Item("aircondition").Value
case 0 response.Write("沒有")
case 1 response.write("有")
case else response.write("不知道")
end select%></td>
<td height="1" nowrap="nowrap">
<%
select case Recordset1.Fields.Item("television").Value
case 0 response.Write("沒有")
case 1 response.write("有")
case else response.write("不知道")
end select
%></td>
<td height="1" nowrap="nowrap"><%=(Recordset1.Fields.Item("price").Value)%></td>
<td height="1" nowrap="nowrap"><%select case Recordset1.Fields.Item("state").Value
case 1 response.Write("空房可用")
case 2 response.write("空房待修")
case 3 response.write("預訂占用")
case 4 response.write("正在占用")
case else response.write("不知道")
end select
%></td>
<td height="1" nowrap="nowrap"><%=(Recordset1.Fields.Item("discription").Value)%></td>
<td height="1" nowrap="nowrap">
<input name="button" type="button" style="font-family:新細明體, 宋體, Arial; font-size: 9pt; height: 20px; background-color: #D4D0C8; color: #FF0000" onClick="window.location='del.asp?roomno=<%=Recordset1.Fields.Item("roomno").Value%>'" onMouseOver="this.style.backgroundColor='#FFC864'"onMouseOut="this.style.backgroundColor='#D4D0C8'" value="預訂"></td>
</tr>
<%
Repeat1__index=Repeat1__index+1
Repeat1__numRows=Repeat1__numRows-1
Recordset1.MoveNext()
Wend
%>
</table>
<form id="form3" name="form3" method="post" action="">
<label>
</label>
</form>
</body>
</html>
<%
Recordset1.Close()
Set Recordset1 = Nothing
%>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -