一个问题!!!

barrytam 2002-06-08 10:04:45
我想用个msgbox在用户端判断yes or no ,然后在服务器端根据该判断进行选择,比如如果用户按了yes那么服务器端i=Rs(1).value,如果按no那么i=Rs(2).value..请问怎样才能实现该功能??
...全文
35 7 打赏 收藏 转发到动态 举报
写回复
用AI写文章
7 条回复
切换为时间正序
请发表友善的回复…
发表回复
yellowwee 2002-06-08
  • 打赏
  • 举报
回复
要是asp.net就很好实现了!·
possible_Y 2002-06-08
  • 打赏
  • 举报
回复
<script language="javascript">
function delit()
{
result="确认要删?\r\n\r\n同时会删除相关信息!"
if (confirm(result))
{
window.location.href="xxx.asp?id=yes";
}
else
{
window.location.href="xxx.asp?id=no";
}
}
</script>
<td><a href="javascript:delit()">删除</a></td>


这样在xxx.asp中:
cid=request("id")
if cid="yes" then
……
Else
……
End if
lanying 2002-06-08
  • 打赏
  • 举报
回复
很简单的呀,判断后提交表但
deavey 2002-06-08
  • 打赏
  • 举报
回复
先在客户端判断,然后在上传msgbox的返回值。在客户端在根据此值来选择。
possible_Y 2002-06-08
  • 打赏
  • 举报
回复
<script language="javascript">
function delit()
{
result="确认要删除该实验?\r\n\r\n同时会删除相关的信息!"
if (confirm(result))
{
window.location.href="xxx.asp?id=yes";
}
else
{
window.location.href="xxx.asp?id=no";
}
}
</script>
<a href="javascript:delit()">删除</a>

在xxx.asp中获取参数id的值,然后判断
cid=Request("id")
if cid="yes" then
……
Else
……
End If
barrytam 2002-06-08
  • 打赏
  • 举报
回复
我不明白的是:在客户端判断后,我应该我怎样才能在服务器端进行判断。我试写了几个语句都实现不了。
MeXP 2002-06-08
  • 打赏
  • 举报
回复
只能在客户端先判断
vbYesNo 4

28,391

社区成员

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

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