I am using php and javascript. I want to delete a record from database after a giving "Yes" and "No" confirmation to user. I am using confirmbox by google but don't know what should be my code structure inside that. I am new to programing. Can any one help me pleaseHow can I add this php function on javascript\[code\]function deleteRecord($id){ $sql = "DELETE FROM user_database WHERE user_id = ".$id; mysql_query($sql) or die("Can not delete");}\[/code\]And on page\[code\]<script type="text/javascript">function show_confirm(){var r=confirm("Press a button!");if (r==true) { alert("You pressed OK!"); }else { alert("You pressed Cancel!"); }}</script></head><body><input type="button" onclick="show_confirm()" value="http://stackoverflow.com/questions/10562925/Show a confirm box" />\[/code\]