algo asi o no
Código PHP:
<html>
<head>
<script>
function confirma()
{
var respuesta=confirm("Pulsa un botón");
if (respuesta==true)
alert("Has pulsado ACEPTAR");
else
alert("Has pulsado CANCELAR");
}
</script>
</head>
<body onLoad=confirma();>
</body>
</html>
Aqui te dejo un link
http://www.elguruprogramador.com.ar/...torial_js1.asp