diff options
Diffstat (limited to 'kjsembed/docs/examples/builtins/messages.js')
-rwxr-xr-x | kjsembed/docs/examples/builtins/messages.js | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/kjsembed/docs/examples/builtins/messages.js b/kjsembed/docs/examples/builtins/messages.js new file mode 100755 index 00000000..4fba62bf --- /dev/null +++ b/kjsembed/docs/examples/builtins/messages.js @@ -0,0 +1,8 @@ +#!/usr/bin/env kjscmd + +var text = prompt("Enter some text.", "Some text"); +var cnf = confirm("Did you really mean to enter " + text ); +if ( cnf == 3) { + alert("Good job entering " + text ); +} else + alert("Maby you need to try harder next time."); |