-
Select Node #1 using the
getElementById()
method, and change the text to: “I used thegetElementById(“node1”)
method to access this” -
Select Node #2 using the
getElementsByClassName()
method, and change the text to: "I used thegetElementByClassName("node2")
method to access this" -
Select ALL the h3 tags using the
getElementsByTagName()
method, and change the text to: "I used thegetElementByTagName("h3")
method to access all of these"
-
Create a paragraph element using this
element.createElement()
and put this text inside "This node was created using thecreateElement()
method" -
Append the created node to the parent node using the
element.appendChild()
method (Keep in mind that you’ll need to select the parent node first) -
Create a
<a>
element using this element.createElement() and put this text inside "I am a<p>
tag" -
Insert the created
<a>
in the parent node, but before the<p>
you just created using theelement.insertBefore()
method -
Add a link href to the
<a>
by selecting theanchorElement.link
property
-
Replace the "Child Node" with a new
<p>
element that reads "New Child Node" using thereplaceChild()
method. -
Remove the "New Child Node" using the
remove()
method orremoveChild()
method.