1 - PHP:Intro - Assignment
Week 1 -
Working with the Date Object - Find any PHP code that lets you display
the date and time on your web page. Make it so that if the second is between
0 and 15 the text is red, 16 to 30 the text is blue, 31 to 45 the text is green,
46 to 60 the text is orange.
25 points
Week 2 -
Using Includes - create 3 .inc php fragments, 1.inc, 2.inc, and 3.inc.
Make each contain a table with the text "this is table1, 2 or 3" in
it, corresponding to the file name. Also, make the background color of the table
in each a different color. Make a php page that uses a "if...elseif...else"
statement to do the following; if the seconds is between 0 and 20, include 1.inc,
if the seconds are between 20 and 40, include 2.inc, and if the seconds are
between 40 and 60, include 3.inc.
Working with variables - In the php page, creat a variable $myVar.
Set it to a value of 10. In each of the 3 php fragment files, create a variable
$myOtherVar. In each file, make $myOtherVar equal to the fragments name number,
ie: 1, 2 or 3. In each fragment file, display the total of $myVar and $myOtherVar.
The total should be different in each file of course.
60 points
This assignment should look something like this