Hello all,

I am not sure if I should post this in this forum or the PHP forum. Basically, I am designing a web application for a school project. On the delete action, I want to prompt the user to make sure they mean delete. I was wanting to use the javascript function alert() but I am open to other suggestions. I am having bad luck googling how to use the alert to prevent my php script from continuing. Can someone either point me to some good reading on this or explain how I can uses this action to act as a Boolean for continuing, thanks,

You should posted in JavaScript section not in JSP that stands for Java Server Pages. Post moved...

You can do something like this

<form action="delete.php or whatever" onsubmit="return confirm('Are you sure?');">

That will pop open a box that says "Are you sure?" with yes and no buttons, if the user clicks no then the form won't submit and nothing will happen, if they click yes the form submits as it should.

commented: Thanks! Sorry for the long wait on it though. +3

Apparently, I never marked this as solved. Sorry, setting to solved and giving Kudos! This answered my question. Thanks.