Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

WEB SCRIPTING >>>>>PHP<<<<<<< Please create a two part form (an .html form and a

ID: 3603066 • Letter: W

Question

WEB SCRIPTING >>>>>PHP<<<<<<<

Please create a two part form (an .html form and a form handler) for one program and create a one part multi data form for the other program.

1. Create/Customize a simple form that would take in information from the user and process the information. (It could take in a list of information from the user and display them). Use your creativity in creating the form and process them to create a usable real-life solution.

2. Create and display an order form that uses all the form elements (text boxes, checkbox, list (single and multiple), radio buttons, text area (for comments), buttons, images. Be creative and try to simulate a real life order form with sizes, quantity, images, etc etc.

Explanation / Answer

<HTML>
<HEAD>
<TITLE>Sample Form</TITLE>
</HEAD>
<BODY>
<FORM name="inputElements" action="program.php" enctype="multipart/form-data" method="post">
Simple Text Box:<INPUT type="text" name="txt" size="5" maxlength="25" value="Hello">
<BR>
Password Text Box:<INPUT type="password" name="pass" size="5" maxlength="25">
<BR>
Check Box:<INPUT type="checkbox" name="falvour" value="Vanilla" checked>
<BR>
Radio Button:<INPUT type="radio" name="gender" value="female" checked>Female
<INPUT type="radio" name="gender" value="male">Male
<BR>
Upload Resume:<INPUT type="file" name="resume">
<BR>
<INPUT type="hidden" name="e-mail" value="me@mysite.com">
<BR>
Submit Button:<INPUT type="submit" name="btnSubmit" value="Ok">
<BR>
Reset Button:<INPUT type="reset" name="btnReset" value="Clear">
<BR>
Image in Button:<INPUT type="image" src="file:///F|/MyMix/Extra Icons/AquaFusion/24x24/apps/blender.png" align="Accept">
<BR>
Button:<INPUT type="button" value="Custom Button" name="btnButton">

<SELECT name="test3" multiple size="8">
<OPTGROUP label="Ice Cream">
<OPTION>Chocolate
<OPTION>Vanilla
<OPTION>Strawberry
<OPTION>Chocolate Chip
<OPTION>Mint Chip
<OPTION>Cookie Dough
<OPTION>Peanut Butter and Chocolate
</OPTGROUP>
<OPTGROUP label="Sorbet">
<OPTION>Raspberry
<OPTION>Lemon
<OPTION>Lime
</OPTGROUP>
<OPTGROUP label="Frozen Yogurt">
<OPTION>Vanilla
<OPTION>Chocolate
<OPTION>Peanut Butter
<OPTION>Raspberry
</OPTGROUP>
</SELECT>
<BR>
Favourite Food:
<SELECT name="food">
<OPTION value="pizza">Pizza</OPTION>
<OPTION value="ice cream" selected>Ice Cream</OPTION>
<OPTION value="eggsham">Green Eggs and Ham</OPTION>
</SELECT>
<BR>
Multiline Text Box:
<TEXTAREA rows="10" columns="30" name="comments">
Please include any comments here.
</TEXTAREA>
<BR>
<BUTTON type="submit">Click here to submit!<IMG src="file:///F|/MyMix/Extra Icons/AquaFusion/24x24/apps/blender.png"></BUTTON>
<BR>
</FORM>
<BODY>
</HTML>