Skip to content

Instantly share code, notes, and snippets.

@MichaelOppong
Created February 17, 2017 17:45
Show Gist options
  • Save MichaelOppong/68ff857f53c2d728acba6dc7083019a2 to your computer and use it in GitHub Desktop.
Save MichaelOppong/68ff857f53c2d728acba6dc7083019a2 to your computer and use it in GitHub Desktop.
Exported from Popcode. Click to import: https://popcode.org/?gist=68ff857f53c2d728acba6dc7083019a2
<!DOCTYPE html>
<html>
<head>
<title>Parts of Speech: We Do</title>
</head>
<body>
<h1 id = "header">This is a page about the parts of speech</h1>
<h1 id = "noun"> This is a noun --> </h1>
<h1 id = "adj"> This is an adjective --> </h1>
<div id ="sentence"></div>
</body>
</html>
/*
WE DO: Variable & jQuery practice
*/
// Variables
// We need to declare a variable called noun and assign it a value in this JavaScript file. How would we do this?
// Append
// How can we append our noun variable to the second h1 tag on this page?
//Student You Do Section
// Challenge #1
// Declare a variable called adjective and assign it a value.
//Challenge #2
//Append your adjective variable to the third h1 tag on this page.
// Challenge #3
// Complete a similar activity for a variable verb. You'll need to add HTML and JavaScript.
// Challenge #4
// Using jQuery, write a sentence using the variables you declared for noun, adjective and verb above. Place this sentence in the div with the ID sentence. (Hint: Remember your operators)
#header{
color: red;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment