Firstly, I've moved this to the HTML/JavaScript forum as there really isn't any
JSP dimension to this.
Secondly, the basic syntax using jQuery and the jQuery UI dialog plugin would be something like:
If you are using your own dialog system, you'd need to adjust accordingly.