<html>
<head>
<title></title>
<script type="text/javascript">
function show_confirm()
{
var r = confirm("Please hoose OK or Cancel");
if(r == true)
{
alert("you hvae click OK");
}
else
{
alert("you hvae click Cancel")
}
}
</script>
</head>
<body>
<input type="button" onclick="show_confirm()" value="show a confirm box"/>
</body>
</html>