Question: M 8 Exercise 1 Create a fluid design In this exercise, you ll convert a page so it uses a fluid layout and scalable images.

M8 Exercise 1 Create a fluid design
In this exercise, youll convert a page so it uses a fluid layout and scalable images. When youre done, the page will look as shown below when the width of the browser window is reduced. Estima1. Open the HTML and CSS files that follow and display the page in a browser:
short_exercises\town_hall\speakers\c07x_sampson.html
short_exercises\town_hall\styles\c07x_speaker.css
2. Reduce the width of the browser window so its less than the width of the page. That way, youll be able to see how the page changes as you convert it to a fluid design.
3. Modify the CSS for the body so it takes up 98% of the browser window and so its maximum width is the current width.
4. Convert the widths of the section, the aside, and the li elements within the navigation menu to percentages.
5. Convert any left or right margins or padding to percentages. (Hint: If any measurements are specified in ems, you can convert them to pixels by multiplying by 16 since thats the base font size.)
6. Make the image in the article scalable so its always 50 percent of the width of the article.
CSS:
/* the styles for the elements */
*{
margin: 0;
padding: 0;
}
html {
background-color: white;
}
body {
font-family: Arial, Helvetictea, sans-d time: 20 to 30 minutes.M8 Exercise 1 Make the image in the Create a fluid design
In this exercise, youll convert a page so it uses a fluid layout and scalable images. When youre done, the page will look as shown below when the width of the browser window is reduced. Estimated time: 20 to 30 minutes.serif;
font-size: 100%;
width: 850px;
margin: 0 auto;
border: 3px solid #931420;
background-color: #fffded;
}
a:focus, a:hover {
font-style: italic;
}
/* the styles for the header */
header {
padding: 1.5em 02em 0;
border-bottom: 3px solid #931420;
background-image: linear-gradient(
30deg, #f6bb730%, #fffded 30%, white 50%, #fffded 80%, #f6bb73100%);
}
header h2{
font-size: 175%;
color: #800000;
}
header h3{
font-size: 130%;
font-style: italic;
}
header img {
float: left;
padding: 030px;
}
.shadow {
text-shadow: 2px 2px 2px #800000;
}
/* the styles for the main content */
main {
clear: left;
}
/* the styles for the section */
section {
width: 575px;
float: right;
padding: 020px 20px 20px;
}
section h1{
color: #800000;
font-size: 150%;
padding-top: .5em;
margin: 0;
}
section p {
padding-bottom: .5em;
}
article {
padding: .5em 0;
}
article h2{
font-size: 115%;
padding: 00.25em 0;
}
article img {
float: right;
margin: .5em 01em 1em;
border: 1px solid black;
}
aside {
width: 215px;
float: left;
padding: 0020px 20px;
}
aside h2{
color: #800000;
font-size: 130%;
padding: .6em 0.25em 0;
}
#nav_list ul {
list-style-type: none;
}
#nav_list li a {
display: block;
padding: 10px;
margin-bottom: 5px;
background-color: #fffded;
color: black;
text-decoration: none;
border: 1px solid black;
border-radius: 5px;
box-shadow: 2px 2px 5px #800000;
background-image: url('../images/right.jpg');
background-repeat: no-repeat;
background-position: 95% center;
}
#nav_list li a:hover, #nav_list li a:focus {
background-color: #cccccc;
color: #800000;
}
footer {
background-color: #931420;
clear: both;
}
footer p {
text-align: center;
color: white;
padding: 1em 0;
}

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!