use it only ....
var del=confirm("Are you sure?");
else must be ignored ..... this is the default function in the confirmation field ... showing "ok" and "cancel" with its own
and this will return true. .if "ok" clicked .. and rteurn false ... if "cancel" clicked
source share