Header Ads

Header ADS

WEB DEVELOPMENT PROJECT PRACTICE BACK END

fast post

<!DOCTYPE html>

<html lang="en">

<head>

    <meta charset="UTF-8">

    <meta name="viewport" content="width=device-width, initial-scale=1.0">

    <title> Interaction - Alert, Prompt, Confirm</title>

</head>

<body>

    <div class="container">

        This is a page 

    </div>

    <script>

        //alert in browser in javascript deas not return

     //alert("Tis is a massege");

     //let name = prompt("what is your name", "name"); Guest

     //this is a prompt

   //  let deletepost = confirm("Do you really want to delete this post");

     //this is a conrfim

   //  if (deletepost){

         //code to delet this post

      //   console.log("your post has been deleted successfully")

    // }

     //else{

         //code not delete this post

        //console.log("your post has been not deleted successfully")

     //}

     //console.log(deletepost);


//let age = prompt("Enter your Age");

//if (age >= 18)

//{

  //alert("Welcome to the club..!");

//}else{

  //alert("Grow up Kid");

//} 

let age = prompt("enter your age");

if (age >= 18)

{

    alert ("welcome to the clube");

}

else

{

  alert("grow up kid")

}

    </script>

</body>

</html>

No comments

Powered by Blogger.