Your first assignment will require you to develop a record processing system in both ASP and PHP, giving you an opportunity to see two modern web scripting languages in action.
You will be provided with an input form for both ASP and PHP, from which you must develop a logically design script which validates and processes the incoming data, presenting the results to screen. Your use of Functions, Control Structures, Input Validation, Conditions, and basic numerical calculations will form the core of each ASP/PHP script.
Your task is to create an ASP and PHP page that reads in the data from the attached forms, validate the data (looking for physical and logical errors), then process the data and output a summary. Your script is required to process a list of units in order to help students figure out how much of their course they have completed and how far they have to go.
The first three fields simply identify the student, while the Course Type field asks the student to choose the type of degree they are studying. After this is 30 rows of records, each recording a unitcode, the credit points that unit is worth (15 or 20), the semester it was studied (Semester 2, 2010 would be 102) and the mark received for the unit. The reason for 30 fields instead of a maximum of 22 is that a student may not have passed all units on the first attempt.
Your job is to write each of your scripts according to the following business logic;
All units that have a mark of 50 or higher have their Credit Points added to a grand total, this total then being subtracted from the Credit Points required for each of the four listed degrees. The total credit points required for each degree is;
Undergraduate - 360
Graduate Diploma - 120
Masters by Coursework - 180
Masters by Research - 240
Thus, if a student fills in 10 rows on the form with units, each unit being worth 15 Credit Points, but has only passed 8 of those units, then the Total Passed Credit Points will be 120, leaving 240 Credit Points Required if they are studying an Undergraduate degree.