I have a delete button that is tied to some comments on a page i have. When you click the delete button i am trying to get a confirm dialog box to pop up asking if you are
Maybe it's because you set the type=submit in the form that contains the javascript.
You should set it to button or image or whatever if you don't want to be submitted if clicked cancel
example of javascript prompt:
function javascript_prompt(){
var name = prompt("Tell me your name.", "");
if (name != "" && name != null){
document.form_name.new_name.value = name;
document.form_name.submit();
}else{
return false;
}
}