Created
March 15, 2017 18:05
-
-
Save kirsten/b1cb48a3d1a43337d53d481fbbbbf615 to your computer and use it in GitHub Desktop.
Exported from Popcode. Click to import: https://popcode.org/?gist=b1cb48a3d1a43337d53d481fbbbbf615
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Page Title</title> | |
</head> | |
<body> | |
<h1>Change the background color!</h1> | |
<input placeholder="Enter a color"> | |
<button>Change background</button> | |
<p>Refer to <a href="https://en.wikipedia.org/wiki/Web_colors#HTML_color_names">this list</a> of HTML color names for color ideas, or try entering hex color codes!</p> | |
</body> | |
</html> |
This file contains 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
{"enabledLibraries":["jquery"]} |
This file contains 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
$('button').click(function() { | |
// Add some jQuery to change the page's background-color css to the color entered in the input field. | |
}); |
This file contains 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
body { | |
font-family: sans-serif; | |
} | |
p { | |
font-size: 12px; | |
margin-top: 20px; | |
font-style: italic; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment