Prompt Box in JavaScript
Prompt Box :
it is same as alert and conform Box but the prompt box we can get a value or message from user./ to get a input from the user
Example:
<!DOCTYPE html> <html> <body> <script> prompt(" what is your name"); </script> </body> </html>
Output: what is your name: xyz
Example:
<!DOCTYPE html> <html> <body> <script> var a= prompt(" what is your name"); alert(a); </script> </body> </html>