• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
SOLVED: double confirm delete
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

SOLVED: double confirm delete


  • Subject: SOLVED: double confirm delete
  • From: Boris Herman <email@hidden>
  • Date: Mon, 13 Mar 2006 21:44:47 +0100

Hi list

perhaps another newbie like me will appreciate this tip: To have an action require double confirmation (WOConfirmPanel only asks once) I did this:
made a dblconfirm.scp file and added it into web resources. Contents of the script file:


function dblconfirm(prompt)
{
 if (confirm(prompt) && confirm("CONFIRM: "+prompt))
 { return true; }
 else
 { alert("Cancelled."); return false; }
}

Added a WOJavaScript to the component (binding scriptFile to "dblconfirm.scp"). For every hyperlink that needs double confirmation I added a custom binding attribute "onClick" with following binding: "return dblconfirm('Really delete the record?')"

It may be a really newbie problem and solution but I am certain that it might be handy to someone else as well as to me.

Regards,
Boris
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Prev by Date: Site management strategies with Subversion
  • Next by Date: Re: Site management strategies with Subversion
  • Previous by thread: Re: Site management strategies with Subversion
  • Next by thread: Macbook Performance!!
  • Index(es):
    • Date
    • Thread