atm959

app.js

Mar 23rd, 2016
226
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. var text;
  2.  
  3. function buttonClick(){
  4. document.getElementById("jsTest").innerHTML = "The button was clicked!!!";
  5. }
  6.  
  7. function resetText(){
  8. document.getElementById("jsTest").innerHTML = "Waiting for input...";
  9. }
  10.  
  11. function onOtherButtonClick(){
  12. alert("The other button was clicked.");
  13. }
  14.  
  15. function typeText(){
  16. text = prompt("Rock, paper, or scissors?");
  17. if(text != null){
  18. document.getElementById("response").innerHTML = "You typed in: \"" + text + "\"";
  19. } else{
  20. document.getElementById("response").innerHTML = "You typed in no text.";
  21. }
  22. }
Advertisement
Add Comment
Please, Sign In to add comment