语法错误 (操作符丢失) 在查询表达式 'ID=' 中。
<%@codepage=936%><!--上面标示采用简体中文形似-->
<!--#include file="../inclub/function.asp" -->
<%
dim sid
sid = request.querystring("sid")
response.Write sid
%>
<!--#include file="../conn.asp" -->
<%
response.charset = "GBK"
if request.form("send") = "添加内容" then
dim rs,sql,gtname,gtnum,hotelbt,Hotelfenlei,Hotelxingji,gtmsj,gtdj,gtimg,Hotelmeet,gtinfo,gtcontent,gtkeyword,id
gtname = request.form("gtname")
gtnum = request.form("gtnum")
hotelbt = clng(request.form("hotelbt"))
Hotelfenlei = clng(request.form("Hotelfenlei"))
Hotelxingji = request.form("Hotelxingji")
gtmsj = request.form("gtmsj")
gtdj = request.form("gtdj")
gtimg = request.form("gtimg")
Hotelmeet = request.form("Hotelmeet")
gtinfo = request.form("gtinfo")
gtcontent = request.form("gtcontent")
gtkeyword = request.form("gtkeyword")
id = request.form("ID")
sid = clng(request.Form("sid"))
set rs = server.createobject("adodb.recordset")
sql="update gt set gtname='">name&"',gtnum=">num&",hotelbt="&hotelbt&",Hotelfenlei="&Hotelfenlei&",Hotelxingji='"&Hotelxingji&"',gtmsj='">msj&"',gtdj='">dj&"',gtimg='">img&"',Hotelmeet='"&Hotelmeet&"',gtinfo='">info&"',gtcontent='">content&"',gtkeyword='">keyword&"',sid="&sid&" where id="&ID
conn.execute(sql)
call sussLoctionHref("内容修改成功","admin_hotel.asp")
end if
showid=request.QueryString("showid")
if showid=""or not isnumeric(showid) then
call errorHistoryBack("非法操作")
end if
set rs2= server.CreateObject("adodb.recordset")
sql2="select *from gt where ID="&showid
rs2.open sql2,conn,1,1
if rs2.eof then
call close_rs2
call close_conn
call errorHistoryBack("不存在此数据")
'以上全部都是验证数据的,验证成功
else
gtname = rs2("gtname")
gtnum = rs2("gtnum")
hotelbt = clng(rs2("hotelbt"))
Hotelfenlei = clng(rs2("Hotelfenlei"))
Hotelxingji = rs2("Hotelxingji")
gtmsj = rs2("gtmsj")
gtdj = rs2("gtdj")
gtimg = rs2("gtimg")
Hotelmeet = rs2("Hotelmeet")
gtinfo = rs2("gtinfo")
gtcontent = rs2("gtcontent")
gtkeyword = rs2("gtkeyword")
sid = clng(rs2("HotelSid"))
end if
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.
transitional.dtd">
<html xmlns="http://www.
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>房间/套餐修改页面</title>
<style type="text/css">
<!--
body,td,th {
font-size: 12px;
}
-->
</style>
<script language="javascript">
// 参数说明
// s_Type : 文件类型,可用值为"image","flash","media","file"
// s_Link : 文件上传后,用于接收上传文件路径文件名的表单名
// s_Thumbnail : 文件上传后,用于接收上传图片时所产生的缩略图文件的路径文件名的表单名,当未生成缩略图时,返回空值,原图用s_Link参数接收,此参数专用于缩略图
function showUploadDialog(s_Type, s_Link, s_Thumbnail){
//以下style=coolblue,值可以依据实际需要修改为您的样式名,通过此样式的后台设置来达到控制允许上传文件类型及文件大小
var arr = showModalDialog("../ewebeditor/dialog/i_upload.htm?style=coolblue&type="+s_Type+"&link="+s_Link+"&thumbnail="+s_Thumbnail, window, "dialogWidth:0px;dialogHeight:0px;help:no;scroll:no;status:no");
}
</script>
</head>
<body>
<form action="admin_hotel_xg.asp" method="post" name="add">
<input type="text" value="<%=sid%>" name="sid" />
<input type="text" value="<%=showid%>" name="id"/>
<table width="90%" border="0" align="center" cellpadding="5" cellspacing="0">
<tr>
<td width="14%" align="center" valign="middle">类别:</td>
<td width="86%" align="left" valign="middle">
<select name="gtnum">
<option value="1" name="gtnum" selected="selected">酒店</option>
<option value="2" name="gtnum">度假</option>
<option value="3" name="gtnum">会展</option>
<option value="4" name="gtnum">美食</option>
<option value="5" name="gtnum">商家</option>
<option value="6" name="gtnum">机票</option>
<option value="7" name="gtnum">租车</option>
<option value="8" name="gtnum">婚纱</option>
<option value="9" name="gtnum">高尔夫</option>
<option value="10" name="gtnum">景点</option>
</select> </td>
</tr>
<tr>
<td width="14%" align="center" valign="middle">名称:</td>
<td width="86%" align="left" valign="middle">
<input name="gtname" type="text" value="<%=gtname%>" /></td>
</tr>
<tr>
<td align="center" valign="middle">区域划分:</td>
<td align="left" valign="middle"><label>
<input type="radio" name="Hotelfenlei" value="1" <%if Hotelfenlei =1 then response.Write"checked='checked'"%> />亚龙湾
</label>
<input type="radio" name="Hotelfenlei" value="2" <%if Hotelfenlei =2 then response.Write"checked='checked'"%> />三亚湾
</label>
<input type="radio" name="Hotelfenlei" value="3" <%if Hotelfenlei =3 then response.Write"checked='checked'"%> />大东海
</label>
<input type="radio" name="Hotelfenlei" value="4" <%if Hotelfenlei =4 then response.Write"checked='checked'"%> />市区
</label>
<input type="radio" name="Hotelfenlei" value="5" <%if Hotelfenlei =5 then response.Write"checked='checked'"%> />海棠湾
</label>
<input type="radio" name="Hotelfenlei" value="6" <%if Hotelfenlei =6 then response.Write"checked='checked'"%> />海口
</label>
<input type="radio" name="Hotelfenlei" value="7" <%if Hotelfenlei =7 then response.Write"checked='checked'"%> />其他地区
</label> </td>
</tr>
<tr>
<td align="center" valign="middle">星级:</td>
<td align="left" valign="middle"><label>
<input type="radio" name="Hotelxingji" value="0" <%if Hotelxingji =0 then response.Write"checked='checked'"%> />家庭旅馆
</label>
<input type="radio" name="Hotelxingji" value="3" <%if Hotelxingji =3 then response.Write"checked='checked'"%> />三星级
</label>
<input type="radio" name="Hotelxingji" value="4" <%if Hotelxingji =4 then response.Write"checked='checked'"%> />四星级
</label>
<input type="radio" name="Hotelxingji" value="5" <%if Hotelxingji =5 then response.Write"checked='checked'"%> />五星级
</label> </td>
</tr>
<tr>
<td align="center" valign="middle">请选择添加类别:</td>
<td align="left" valign="middle"><label>
<input type="radio" name="hotelbt" value="1" <%if hotelbt =1 then response.Write"checked='checked'"%> />房间
</label>
<input type="radio" name="hotelbt" value="2" <%if hotelbt =2 then response.Write"checked='checked'"%> />套餐
</label>
</td>
</tr>
<tr>
<td align="center" valign="middle">是否有会场:</td>
<td align="left" valign="middle"><label>
<input type="radio" name="Hotelmeet" value="1" <%if Hotelmeet =1 then response.Write"checked='checked'"%> />有
</label>
<input type="radio" name="Hotelmeet" value="2" <%if Hotelmeet =2 then response.Write"checked='checked'"%> />没
</label>
</td>
</tr>
<tr>
<td align="center" valign="middle">价格:</td>
<td align="left" valign="middle"><input name="gtmsj" type="text" value="<%=gtmsj%>" />
>>门市价
<input name="gtdj" type="text" value="<%=gtdj%>" />
>>优惠价</td>
</tr>
<tr>
<td align="center" valign="middle">图片:</td>
<td align="left" valign="middle"><input type=text name=gtimg value="<%=gtimg%>" size=50> <input type=button value="上传图片..." onClick="showUploadDialog('image', 'add.gtimg', '')"> </td>
</tr>
<tr>
<td align="center" valign="middle">简介:</td>
<td align="left" valign="middle">
<textarea cols="50" rows="5" name="gtinfo" ><%=gtinfo%></textarea> </td>
</tr>
<tr>
<td align="center" valign="middle">内容:</td>
<td align="left" valign="middle">
<input type="hidden" name="gtcontent" value="<%=Server.HTMLEncode(gtcontent)%>" />
<IFRAME ID="eWebEditor1" SRC="../ewebeditor/ewebeditor.htm?id=gtcontent&style=standard650" FRAMEBORDER="0" SCROLLING="no" WIDTH="650" HEIGHT="350"></IFRAME> </tr>
<tr>
<td align="center" valign="middle">关键字</td>
<td align="left" valign="middle"><input type="text" name="gtkeyword" value="<%=gtkeyword%>"/>
(多个关键字请使用英文逗号“,”隔开)</td>
</tr>
<tr>
<td align="center" valign="middle"> </td>
<td align="left" valign="middle"><input type="submit" onclick="return check();" name="send" value="修改内容" /></td>
</tr>
</table>
</form>
</body>
</html>
<%
call close_conn
%>
只差一步了... showid的值也出现了 但是不知道为什么 ID="&showid 时 showid就是付不上值 在线等