UCF
University of Central Florida
CIS 4004 Web Based Information Technology
Page 2 of 2
Assignment 3
Due, Monday, July 25, 2022 for 100% credit
Tuesday, July 26, 2022 for 90% credit
Wednesday, July 27, 2022 for 80% credit
Thursday, July 28, 2022 for 70% credit
Assignment scope
This assignment is focused on writing PHP and will create an electronic version of a dice game Boggle.
This project will require students to randomly generate a Boggle board. The player will have three minutes to find as many words as possible. Words are created with three letters or more. Words are formed from adjoining letters. Letters must join in the proper sequence to spell a word. Letters may join horizontally, vertically, or diagonally, to the left, right, up or down. No letter cube may be used more than once in a single word.
Resources
xampp
1. Use the popular bundled tool XAMPP (i.e. pronounced ‘zamp’)
a. https:
www.apachefriends.org/download.html
2. What to do with XAMPP once installed
a. http:
www.phpknowhow.com
asics/working-with-xampp/#:~:text=Go%20to%20the%20location%20where,right%20of%20your%20task%20bar.
Two files have been provided as templates for this assignment
1. boggle.css
2. boggle.php
Assignment submission
Create a single folder for the two files, the .css and .php. Compress the folder and submit the compressed file (e.g. .zip)
Tasks
Activity
.css
1. Modify the provided style settings
a. background color for Boggle dice
. font color for Boggle dice
c. background color for Enter button
d. font color for Enter button
.php
1. Inside the open/close do the following
a. define constant SIZE with the value of 4
. create variable data set equal to the Boggle letters as a string (i.e. see figure 1)
c. define variable letters set equal to converting data string to character a
ay using str_split() function
d. Write function getLetter() to do the following
i. Parameter list includes the letters a
ay
ii. Call function shuffle(), passing the letters parameter as an argument
iii. create variable size set equal to the size of the a
ay using function count(),passing the letters parameter as an argument
iv. create variable idx set equal to function rand() passing as arguments, 0 and variable size
v. declare variable letter set equal to the letters a
ay at index idx
vi. Return the variable lette
e. Build the HTML by doing the following
i. display as an