javascript确认框提示框

#   javascript确认框提示框



<html>
<head>
<script type="text/javascript">
function show_confirm()
{
var r=confirm("Press a button!");
if (r==true)
  {
  alert("You pressed OK!");
  }
else
  {
  alert("You pressed Cancel!");
  }
}
</script>
</head>
<body>

<input type="button" onclick="show_confirm()" value="Show a confirm box" />

</body>
</html>


# xiaoxiao [ 2015-11-30 ]

# Address in this article

# http://www.s7smile.com/javascript/3

# s7smile.com