帮忙看一下!这是什么问题??

shizhenyi 2002-05-20 02:53:16
提交后有保存到数据库里,但资料没添加进去只有加入一个ID号

set rs=server.createobject("adodb.recordset")
sql="select * from qeye"
rs.open sql,conn,1,3

rs.addnew
rs("lind_named")=named
rs("lind_content")=content
rs("lind_leanxi")=leanxi
rs("lind_kind")=kind
rs("lind_ip")=ip
rs("lind_danhuae")=danhuae
rs("lind_fax")=fax
rs("lind_ipe")=ipe
rs("lind_ub")=ub
rs("datetime")=date()
rs("lind_url")=url
rs.update
rs.close
set rs=nothing
response.write"<script canguage='javascript'>" & chr(13)
response.write"alert('已经成功加入,请按确定返回!')" & chr(13)
response.write"window.document.location.href='huabu-qyml.asp';" & chr(13)
response.write"</script>" & chr(13)
response.end
end if


...全文
42 9 打赏 收藏 转发到动态 举报
写回复
用AI写文章
9 条回复
切换为时间正序
请发表友善的回复…
发表回复
possible_Y 2002-05-20
  • 打赏
  • 举报
回复
rs.open sql,conn,1,3改为rs.open sql,conn,3,3
xxjmz_78 2002-05-20
  • 打赏
  • 举报
回复
ChinaOK(授人以鱼,不如授人以渔)说得对
你把表单里的值用request("name")赋给一个变量,我想这里的name一定是个text控件吧
ssm1226 2002-05-20
  • 打赏
  • 举报
回复
没报什么错?
shizhenyi 2002-05-20
  • 打赏
  • 举报
回复
有赋值就是加不进去,日期也没加入呀
jie2002 2002-05-20
  • 打赏
  • 举报
回复
对啊,你还没赋值呢,可以这样:
rs("lind_named")=request("name")
ssm1226 2002-05-20
  • 打赏
  • 举报
回复
看看
rs("datetime")=date()
加进去没。
再用楼上的检查一下那些变量有没有值
wangfei2428 2002-05-20
  • 打赏
  • 举报
回复
id好添加进去,说明记录已经插入,请检查您的变量是否付值,
name=request("name")
response.write name
response.end
看看网页上有什么
cmsoft 2002-05-20
  • 打赏
  • 举报
回复
named
content
leanxi
kind
ip
……
你这些变量的值赋了没有?
ChinaOk 2002-05-20
  • 打赏
  • 举报
回复
这就说明你的那些变量没有赋值了。

先 name=request("name")
leanxi=request("leanxi")
................

28,391

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧