Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

javascript alert get text

var person = prompt("Please enter your name", "Harry Potter");

if (person == null || person == "") {
  txt = "User cancelled the prompt.";
} else {
  txt = "Hello " + person + "! How are you today?";
}
Comment

PREVIOUS NEXT
Code Example
Javascript :: momeny day in range 
Javascript :: nextjs custom document 
Javascript :: how to reverse a string in javascript 
Javascript :: JavaScript how to put value 
Javascript :: how to always run validators mongoose 
Javascript :: splidejs example 
Javascript :: how to master javascript 
Javascript :: split date in javascript 
Javascript :: how to generate color code from random number 
Javascript :: js sort 1 or -1 
Javascript :: phaser 3 add button 
Javascript :: js code stars 
Javascript :: jquery serialize form data to object 
Javascript :: how to pretty formatjson value on terminal ruby 
Javascript :: USA phone number validator angular 
Javascript :: jest testmatch specific folder 
Javascript :: session check in javascript 
Javascript :: javascript get random items from array 
Javascript :: javascript how to ceil number 
Javascript :: close tab using jquery 
Javascript :: javascript add hours 
Javascript :: replace comma by new line in js 
Javascript :: scrollview refresh 
Javascript :: sample google map api key for testing 
Javascript :: onclick open link js 
Javascript :: javascript how to check if object property exists 
Javascript :: remove single item from array in angular 
Javascript :: async await anonymous function 
Javascript :: js filter array of objects by value 
Javascript :: hide a div when user clicks outside of it 
ADD CONTENT
Topic
Content
Source link
Name
5+3 =