JavaScrip救命阿30分全给了
<a href= 'DeleteUser.jsp?UserID= <%=rs.getString( "UserID ")%> '> 删除用户 </a>
删除用户是一个超链接 如何弹出一个确定和取消的对话框 如何点确定者进行连接
取消的话不进行任何操作
------解决方案--------------------Easy
L@_@K
<body>
<a href= '# ' onclick= 'comfirmDeleteUser( <%=rs.getString( "UserID ")%> ) '> 删除用户 </a>
<script type= "text/javascript ">
<!--
function comfirmDeleteUser(strUserId)
{
if (confirm( "确认删除所选用户? "))
{
var currentPath = window.location.href.substring(0, window.location.href.lastIndexOf( "/ ")+1);
window.location.href = currentPath + "DeleteUser.jsp?UserID= " + strUserId;
}
}
//-->
</script>
</body>