Question: Hello, please help me fix my CGI JavaScript web page. -------------------------------------------------------------------------------------------- ERROR MESSAGE: lottery1210.cgi:11 Uncaught TypeError: Math.Random is not a function at displayImages (lottery1210.cgi:11) at

Hello, please help me fix my CGI JavaScript web page.

--------------------------------------------------------------------------------------------

ERROR MESSAGE:

lottery1210.cgi:11 Uncaught TypeError: Math.Random is not a function at displayImages (lottery1210.cgi:11) at HTMLInputElement.onclick (lottery1210.cgi:29)

MY CODE:

#! /bin/bash echo "Content-type: text/html" echo ""

cat

Lottery

var imagesArray=["http://jd-cit160a.ecs..edu/img/img_0.jpg","http://jd-cit160a.ecs..edu/img/img_1.jpg","http://jd-cit160a.ecs..edu/img/img_2.jpg","http://jd-cit160a.ecs..edu/img/img_3.jpg","http://jd-cit160a.ecs..edu/img/img_4.jpg","http://jd-cit160a.ecs..edu/img/img_5.jpg","http://jd-cit160a..edu/img/img_6.jpg"]

function displayImages() {

var num=Math.floor(Math.Random()*5);

document.cccc.src=imagesArray[num];

}

Welcome to our Lottery Game!

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!