Course Solutions Uncategorized (Solved) : Create File Data Colourlistjs Creates Global Array Called Colourlist Containing List 5 Col Q31044566 . . . .

(Solved) : Create File Data Colourlistjs Creates Global Array Called Colourlist Containing List 5 Col Q31044566 . . . .

 

Create a file data/colourList.js , which creates a global arraycalled colourList, containing a list of 5 colours (e.g. “red”,”blue”, etc).

In your week5a.js file, create a button “Randomise Colour” whichcalls a function randomiseBackgroundColour(). This function, whenexecuted, will select a random colour from our colourList array,and change the document BODY element’s background colour.

In addition to the aforementioned button, create a vertical listof buttons for each colour in the colourList. Each buttons textshould be the colour name. When that button is clicked, thedocument BODY’s background colour will specifically change to thebutton’s colour.

Further to the last step, colour the background of each buttonto be

OR

PayPal Gateway not configured

OR

PayPal Gateway not configured

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post