Latest Tutorials| Questions and Answers|Ask Questions?|Site Map

Home Answers Viewqa JavaScriptQuestions JavaScript Alert YES NO

Have Programming Question? Ask it here!

Java Coder
JavaScript Alert YES NO
2 Answer(s)      2 years and 3 months ago
Posted in : JavaScript Questions

How to send an alert to a user to confirm if there request is valid or not? I wants to send the alert message in Java Script.

View Answers

April 7, 2012 at 12:41 PM

You can use the confirm() method in Java Script.

if (confirm('Are you sure you want to save this thing into the database?')) {
    // Save it!
} else {
    // Do nothing!

April 7, 2012 at 12:54 PM

<script type="text/javascript">
function show_alert(my_string)

<input type="button" onclick="show_alert('This will alert!')" value="Show alert box" string="alert for system number 2" />


Related Tutorials/Questions & Answers:
JavaScript Alert YES NO
JavaScript Alert YES NO  How to send an alert to a user to confirm if there request is valid or not? I wants to send the alert message in Java Script... type="text/javascript"> function show_alert(my_string) { alert(my_string
javascript confirm yes no
javascript confirm yes no  javascript confirm yes no - how to create confirm dialog box yes or no in JavaScript?   if (confirm('Are You... are not redirected") }   How to confirm yes or no in JavaScript
javascript prompt alert
javascript prompt alert   Sending a prompt alert using a JavaScript function
Javascript alert message
Javascript alert message   How to send an alert message to a user in JavaScript
javascript statement alert
javascript statement alert  JavaScript Alert If Statement   JavaScript Alert if Statement <script type="text/javascript"> <...;/script> JavaScript Alert else if Statement <script type="text/javascript
JavaScript display variable in alert
JavaScript display variable in alert  How to display variable in alert box? I am using javascript.   <html> <head> <script type="text/javascript"> function showAlert() { var name = "Roseindia
alert  after pressing ok button in alert message it has to stop...; if(username==""){ alert("Enter Username!"); return false; } if(password==""){ alert("Enter Password!"); return false; } return true; } </script> <
Alert in Servlet
Alert in Servlet  <p>Hi</p> <p>I want to delete record from oracle db, i need alert message saying 'Are you sure you want to delete?' with yes and no buttons, if yes, the data should delete if no control
alert for validation
alert for validation  i want to put alert on the text box that enter data should be in DD/MM/YYYY format only through javascript validation.    <html> <script type='text/javascript'> var
fast view web--yes - Struts
fast view web--yes  How to enable the fast web view--yes on pdf file  Hi Friend, Please clarify your problem. Thanks
Yes/No confirm box with vbscript - Framework
Yes/No confirm box with vbscript  I'm using a Yes/No confirmation with vbscript. But the in the confirm box, the titiel is coming along with 'VBScript' in it. I just want to remove this 'VBScript' title, Can anyone help me
alert in jsp
alert in jsp  if(pass.equals(pwd)) { Statement st1..."); %> alert("password is successfully changed"); <... Password"); %> <script> alert("please enter old Password
[[UIApplication sharedApplication] setStatusBarHidden:YES animated:NO] is depricated
[[UIApplication sharedApplication] setStatusBarHidden:YES animated... the status bar hidden. [[UIApplication sharedApplication] setStatusBarHidden:YES...: [[UIApplication sharedApplication] setStatusBarHidden:YES]; Thanks
change appearance of alert box
change appearance of alert box  how to change the appearance of an alert() box
jQuery alert()
jQuery alert() In this jQuery tutorial we will discuss how an alert box works in jQuery. Moreover, this tutorial will discuss in details about alert box in jQuery. In the given application here, alert boxes have been used to provide
JSP Alert
JSP Alert          JSP Alert is used to put the validation on login... the validation on the login form using Javascript method in JSP page.  Understand
GETTING ALERT MESSAGE  how to get an alert message when radio button is selected instead of checkbox
GETTING AN ALERT MESSAGE  how to get an alert message, if i select radio button instead of checkbox(associated with 3 dropdown list
alert box in iphone
alert box in iphone  hello, how can i show alert box in my iphone application??   hello, you can use this code for show the alert .. UIAlertView *alt = [[UIAlertView alloc] initWithTitle: @"Title" message: @"Any
Javascript   Javascript to check Numeric entry in checkbox.....  ... in javascript function validateBox(){ var data=document.myForm.someText.value; if(data=="" || data==null){ alert("Please Input Data
jQuery Hello World alert
will use the JavaScript alert() method to display the "Hello World" message... in the curly braces{}. In the curly braces we have defined the JavaScript alert() method... jQuery Hello World alert example    
jQuery alert()
jQuery alert() In this section we will discuss about alert box in jQuery. In an application alert boxes are used to provide information at run time... information at runtime. Alert box can be popped up after happening an event
Getting content of alert message into textfield
Getting content of alert message into textfield  how to get content of alert message into textfield using javascript   Getting content of alert message into text field 1)If you want the code in java, then here
Getting content of alert message into textfield
Getting content of alert message into textfield  how to get content of alert message into textfield using javascript   Getting content of alert message into text field 1)If you want the code in java, then here
this format xxx-xxx-xxxx, i want the code in javascript. as a function.   Javascript Phone Number Validation <html> <script> function...)-(\d\d\d)-(\d\d\d\d)/; if(ph==""){ alert("Enter Phone Number!"); } else
Alert Control in Flex4
Alert control in Flex4: The Alert control is a MX component. It has no Spark component. The Alert control contains a message, icon, title, and buttons. Flex uses the show() method of the Alert classfor open a dialog box. The Syntax
Access denied for user 'abc'@'xxxx' (using password: YES)
Access denied for user 'abc'@'xxxx' (using password: YES)  I have tested my code on local machine DB, its working correctly.. But when i shifted it to server DB using URL, Username and password.. i got this error .. How can i
/javascript"> function validateForm() { var sname=document.getElementById('spocname...<10){ alert('enter min 10 characters'); sname.focus(); } if(scontact.value.length>10){ alert('enter less than 10 characters'); scontact.focus
java hello and timer alert application
java hello and timer alert application  Hi, Please help me create a simple Java application that can display "Hello world" and current Time alert on mobile device screen using mobile screen emulator. Regards
javascript validation
javascript validation  i have 4 buttons in my project like save,find,modify,clear and exit. Here my problem is i have to validate in javascript like if i click on save button an alert message should be displayed "DO YOU WANT
JavaScript  clone JavaScript
javascript  Hi deepak, sample example on javascript form validation...)){ return 1; } else{ alert("Please enter a valid name. The only charachters...) { if(isNaN(text)){ return 1; } else{alert("Please enter a valid address. The only
(theForm.radios); if (why != "") { alert(why); return false; } return true; } function
Flex Alert Box example
Flex Alert Box example       Alert box is a dialog box that appears on window with some message and stays rigid until the event associated with it is not done. Alert
why alert box is not appearing in servlets...?
why alert box is not appearing in servlets...?  // import*; import javax.servlet.*; import javax.servlet.http.*; public class adduser extends HttpServlet { public void init(ServletConfig config
); if (why != "") { alert(why); return false; } return true; } function... != "") { alert(checkD); return false; } if (checkR != "") { alert(checkR
javascript  javascript code to dynamically add table on button click.../javascript/javascriptexamples/javascript-add-row-dynamically.shtml
Javascript  How validations are done using javascript ,with example? and interview questions on javASCRIPT
Alert Box in Flex
Flex Alert Box Components Adobe Flex provides many types of components, in this tutorial we will study visual component. 1. Alert Box: In the present tutorial we will see how to display simple text using Alert Box. An Alert Box
javaScript  How to open a browser window that cannot be resized? (HTML + Javascript
javascript  write a program to display implement about browsers using javascript
javascript  Hi deepak, how to write form validation on javascript
JavaScript  how to get full path of a file type in javascript
should use JavaScript? Thanks   Hi, JavaScript is scripting language that runs on browser. You have to embed JavaScript in HTML page. Please see JavaScript tutorial. Thanks
javascript  i have just learned javascript... can you tell me what kind of applications can be made by javascript?? thank you
J2ME Alert Example
J2ME Alert Example      ... to create  alert through sound. In this example we are using AlertType class for the different alert. The AlertType() class has only one method: playSound
javascript  Hi sir, This is sinduri, i want to learn javascript, so plz can u help to learn
javascript  hi sir, if i want to learn javascript. what concepts i want to know
javascript  how to set the request or session attribute in javascript head part of jsp page