Loading ...
Sorry, an error occurred while loading the content.

how to get confirmation window ?

Expand Messages
  • Jayaprasad Rao K
    My application is like, when I press a function button (with Java aplet), a PHP function will be called where I delete one record in database. Now, I would
    Message 1 of 3 , Sep 6, 2006
    • 0 Attachment
      My application is like, when I press a function button (with Java
      aplet), a PHP function will be called where I delete one record in
      database.

      Now, I would like to add confirmation window, that is, once the delete
      function button is pressed, one more confirmation window should appear
      (with YES/NO option) and delete the record only if I click YES.

      How to do this with PHP ?
    • ansar ansar
      Hi Jayaprasad, Its simple just use the below code
      Message 2 of 3 , Sep 6, 2006
      • 0 Attachment
        Hi Jayaprasad,

        Its simple just use the below code

        <form method="POST" action="ansar.php">
        <input type="hidden" name="accountid" value="23948234">
        <input type="submit" name="delete"
        value="Delete Record"
        onClick="return confirm(
        'Are you sure you want to delete?');">
        </form>

        This is simple code when you click the delete button the confirmation window is popped up.. if you click on yes the form will submit if no the form is not submitted.. You can use same or modify as you like.

        Jayaprasad Rao K <jprao@...> wrote:
        My application is like, when I press a function button (with Java
        aplet), a PHP function will be called where I delete one record in
        database.

        Now, I would like to add confirmation window, that is, once the delete
        function button is pressed, one more confirmation window should appear
        (with YES/NO option) and delete the record only if I click YES.

        How to do this with PHP ?






        ---------------------------------
        Here's a new way to find what you're looking for - Yahoo! Answers
        Send FREE SMS to your friend's mobile from Yahoo! Messenger Version 8. Get it NOW

        [Non-text portions of this message have been removed]
      • Vishwanath B
        hi we can use javascript fuction for this....(built in function is there giving Yes/No option) when u click on that button call that function using onClick()
        Message 3 of 3 , Sep 6, 2006
        • 0 Attachment
          hi
          we can use javascript fuction for this....(built in function is there giving Yes/No option)
          when u click on that button call that function using "onClick()" method.
          the "button type" should be "button" not submit.

          Jayaprasad Rao K <jprao@...> wrote:

          My application is like, when I press a function button (with Java
          aplet), a PHP function will be called where I delete one record in
          database.

          Now, I would like to add confirmation window, that is, once the delete
          function button is pressed, one more confirmation window should appear
          (with YES/NO option) and delete the record only if I click YES.

          How to do this with PHP ?






          ---------------------------------
          Stay in the know. Pulse on the new Yahoo.com. Check it out.

          [Non-text portions of this message have been removed]
        Your message has been successfully submitted and would be delivered to recipients shortly.