How to create an input box?

Ads
 

How to create an input box?

How to create an input box?

View Answers

November 10, 2010 at 6:05 PM

A prompt box is often used if you want the user to input a value before entering a page.

When a prompt box pops up, the user will have to click either "OK" or "Cancel" to proceed after entering an input value.

If the user clicks "OK" the box returns the input value. If the user clicks "Cancel" the box returns null.

<script type="text/javascript">
         var name = prompt("What is your name", "Type you name here");
document.write("Hi " + name + "\nHope you are enjoying JavaScript!");
      </script>

Ads









Related Tutorials/Questions & Answers:
How to create file from input values in Jframe ?
ModuleNotFoundError: No module named 'box0'
Advertisements
ModuleNotFoundError: No module named 'boxr'
Create a Program that Calculates Input
ModuleNotFoundError: No module named 'boxb'
ModuleNotFoundError: No module named 'boxb'
ModuleNotFoundError: No module named 'boxx'
ModuleNotFoundError: No module named 'boxx'
ModuleNotFoundError: No module named 'boxy'
ModuleNotFoundError: No module named 'boxy'
ModuleNotFoundError: No module named 'boxx'
ModuleNotFoundError: No module named 'boxy'
ModuleNotFoundError: No module named 'boxd-client'
Create a input button inside js function
How to create simple HTML Form?
How to read user input in C++
how to create frame in swings
how to create notepad in java
how to create session for login
how to create using jsp
How to create form in Swings
How to create a class in java
how to create web aplli
how to create web aplli
How to Create Keyboard in JAVA
how to create a table
How To Create a Table.
how to create rdd in pyspark
how to create uiwebview programmatically
how to create ipa file
How to create charts in Java?

Ads