I am displaying a confirm box in my app. When the user clicks on Okay, I close the window
when user clicks on Cancel, I want to do nothing but stay on the same page.
What should I write in place of DO_NOTHING?
<a href="#" onclick="confirm('Do you wan to close the application ?')?window.close():DO_NOTHING')">Close the application ?</a>
If I keep it empty it does not work. If I write any random string it works but displays string undefined error.
Just have this instead:
No point of using the
x?y:zif you don’t intend to use it “fully”.