Question: how would i code this with javascript? 5 Create an aside element with the ID keywords and containing an h1 heading with the text Keyword

how would i code this with javascript?

5

Create an aside element with the ID keywords and containing an h1 heading with the text Keyword List.

6

Create an ol element and append it to the keywords aside element.

my code:

"use strict";

/*

New Perspectives on HTML5, CSS3 and JavaScript 6th Edition

Tutorial 12

Review Assignment

Author:

Date:

Filename: bc_keys.js

Functions

=========

findKeyWords()

Locate the keywords in the article indicated by the tag

and add those keywords in alphabetical order to a keyword box.

makeKeyStyles()

Create an embedded style sheet for the keyword box.

replaceWS(textStr)

Replaces occurences of one or more consecutive white space

characters with the _ character.

*/

/* functions when the page is loaded */

window.addEventListener ("load", findKeyWords);

window.addEventListener ("load", makeKeyStyles);

findKeyWords() {

}

/* Supplied Functions */

function replaceWS(textStr) {

var revText = textStr.replace(/\s+/g,"_");

return revText;

}

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!