Only last two steps left !!!
it won’t take more than 10 minutes if u r familiar with PHP.
<html>
<head>
<style>
table, th, td {
border: 1px solid black;
}
</style>
</head>
<center>
<body>
<table border=”1″ action=”PreLab4.php” method=”post”>
<tr>
<td><p style=”color:blue”><i>Which dessert would you like?</i></p>
<select id=”mySelect” onchange=”myFunction()” >
<option value=”0″>None
<option value=”1″>chocolate
<option value=”2″>icecream
<option value=”3″>fruit
<option value=”4″>brule
</select></td>
<td>
<img id=”image” src=”” width=”300″ height=”200″>
<script>
function myFunction( ) {
var x = document.getElementById(“mySelect”).value;
if (x < 1){
document.getElementById(“image”).src =””;
}else if (x < 2){
document.getElementById(“image”).src =”chocolate.jpg”;
}else if (x < 3){
document.getElementById(“image”).src =”icecream.jpg”
}else if (x < 4){
document.getElementById(“image”).src =”fruit.jpg”
}else{
document.getElementById(“image”).src =”brule.jpg”}
}
</script>
</td>
</tr>
<tr>
<th colspan=”2″>
<p style=”font-weight:normal”>
<form style=”text-align:left” >
Do you like writing exams?
<input type=”radio” name=”writingexam” value=”Love”> Love
<input type=”radio” name=”writingexam” value=”Like” checked> Like
<input type=”radio” name=”writingexam” value=”Dislike”> Dislike
<input type=”radio” name=”writingexam” value=”Despise”> Despise
</form>
</p>
</th>
</tr>
<tr>
<th colspan=”2″>
<form style=”text-align:left”>
First Name: <input type=”text” name=”firstname” required>
Last Name: <input type=”text” name=”lastname” required>
</th>
</tr>
<tr>
<th colspan=”2″ style=”text-align:left” >
<input type=”submit”>
</form>
</th>
</tr>
</table>
</body>
</html>
</center>