Confirm Dialog Box in JavaScript || JavaScript Dialog Box

In this video,I explained the Confirm Dialog Box in JavaScript. Feel free to comment. For more, please subscribe and press the BELL icon.  Please visit my JS Playlist. The code is as follows -

HTML Code -
<html>
 <head>
     <title> Confirm Dialog Box </title>
 </head>

 <body>
   <script language="javascript">
     var x= confirm("Press any two Buttons");
      if (x == true)
  { 
alert("I have pressed OK ...!!!");
  }
  else
  {
alert("I have pressed the Cancel Button ...!!!");
  }
 
   </script>
 </body>
</html>


Comments

Popular posts from this blog

Event Binding and Event Filtering || Displaying Data and Handling Events

Service in Angular || Dependency Injection || Angular Fundamentals

Property and Attribute Binding in Angular || Displaying Data and Handling Events