Threesuns

Email the Instructor

Contact

All Semesters

Semesters

All Courses

Courses

2016Fall

08.17.15 - 12.13.15

PHP Programming (Online)

CSYS2463

Online
12:00 AM - 12:00 AM

Boxes

Lab03

Objective: Practice using forms and control structures

pastdue

Submit Your Solution

Lab03

Requirements

Generated page is valid10 pts
Form is available as specified10 pts
Box is drawn correctly based on form submission50 pts
Form is validated correctly with markings30 pts
Total100 pts

Instructions

Overview

For this lab you will need to create a single page PHP script that allows a user to submit a width and height that the page will then use to draw a box.

The Box

Your script can "draw" a box on the page by setting the width and height for a div whose border is shown. The box should only be shown when a valid width and height are available.

The Form

The form should allow the user to specify a width and a height for a box using textfields with labels. When the form is submitted it should be submitted back to the same page (self-submitting page) and that page should then process the width and height that were submitted.

Validation

If the form has not been submitted it should appear as normal. If a width and height have been submitted those values should be (re)displayed in the width and height fields. If a submitted width or height is blank, non-numeric, or less than or equal to zero, then the field containing the invalid value should have a red border and the field's label should appear as red.