Last active
December 12, 2015 04:19
-
-
Save thehack/4713458 to your computer and use it in GitHub Desktop.
Some JavaScript Tricks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- This goes under your link menu if you have one --> | |
<h1>Some Javascript Tricks</h1> | |
Name: <input id="name" type="text" onkeyup="document.getElementById('response').innerHTML = 'Hi, ' + this.value + '. I hope you enjoy this.';"> | |
<br> | |
Color: <input id="color" type="text" onkeyup="document.body.style.backgroundColor=this.value;"> | |
<p id="response"></p> | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment