====== Web Development Lesson 8 - Forms ======
===== Styling =====
==== Objective ====
In this activity you will improve the appearance of your forms.
==== Setup ====
* We'll continue to use 'form.php' and 'style.css' in this activity. In case you need the code again, here it is.
**form.php**
prepare($query);
$hrslt->execute($args);
// get list of movies
$query = "SELECT * FROM appearances GROUP BY movie";
$args = array();
$mrslt = $pdo->prepare($query);
$mrslt->execute($args);
?>
**style.css**
ol {
color: blue;
}
ol ol {
font-weight: 700;
}
ul {
list-style-type: none;
}
td, th {
border-width: 1px;
border-style: solid;
}
td {
padding: 10px;
}
table {
border-collapse: collapse;
}
header {
background-color:indianred;
border:darkred solid 2px;
height: 100px;
position: absolute;
left: 16%;
right: 0px;
top: 0px;
}
nav {
background-color: burlywood;
border:yellow solid 2px;
position: fixed;
top: 0px;
bottom: 0px;
width: 16%;
left: 0px;
}
main {
background-color: lightgree;
border: darkgreen solid 2px;
position: absolute;
top: 100px;
left: 16%;
right: 0px;
bottom: 80px;
overflow: scroll;
padding: 20px;
}
footer {
background-color: lightskyblue;
border: darkblue solid 2px;
position: absolute;
bottom: 0px;
height: 80px;
left: 16%;
right: 0px;
}
.content {
background-color:coral;
border:orangered solid 2px;
height: 400px;
padding: 40px;
margin: 20px;
display: inline-block;
width: 300px;
}
img {
float: left;
max-height: 250px;
border: solid 2px green;
margin: 20px 20px 20px 0px;
padding: 10px;
border-radius: 30px;
}
#album {
display: flex;
justify-content:space-between;
flex-wrap: wrap;
}
video {
max-height: 250px;
float: right;
clear: left;
margin: 20px 0px 20px 20px;
padding: 10px;
}
audio {
margin: 20px 20px 20px 0px;
padding: 10px 10px 10px 0px;
}
input[type=button] {
display: block;
}
figcaption {
display: block;
text-align: center;
font-family: 'Arial', sans-serif;
color: green;
}
==== Fieldsets ====
* Save and upload the code if you need to.
* Open 'form.php' in your browser and take a look.
* What do you think needs improving?
* The first thing I notice is that everything is piled up together. It needs to be spaced out to make it more readable.
* Let's start by separating out the two sections of the form.
* Add a