CLASSIC ASP QUERY

时间:2010-08-25 06:22:34

标签: asp-classic

do until rs1.eof             

elseif year(tDate) = year(now) then

elseif rs1("leavetype") = 1 and (rs1("statusLev1") = "z" and rs1("statusLev2") = "z") then
                    childcare = childcare + rs1("totaldays")

elseif rs1("leavetype") = 28 and (rs1("statusLev1") = "P" and rs1("statusLev2") = "P") then
 %>
<script>alert("You are...")
history.go(-1)</script>
<%** 
    end if

         end if
    rs1.movenext
    loop
    rs1.movefirst   

在提交leavetype = 28之后,我无法应用任何其他假期,因为消息框正在显示。我只有在申请休假类型28并且状态级别为p时才显示消息框。否则我不会需要留言1或2.如何修改..? 感谢

1 个答案:

答案 0 :(得分:1)

ASP在服务器端执行,<script>....在客户端站点上执行。

您正在寻找的是(我认为)

Response.Write("<script>alert(""You are...""); history.go(-1)<script>")

关于%><%。所以编写javascript代码,使其出现在客户端html。