Okay, I am brand new to CSS and this forum, so please be patient with me
I am learning CSS though lynda.com and am watching the tutorial, “CSS Page Layouts,” http://www.lynda.com/CSS-tutorials/Positioning-elements-Lab/86003/97829-4.html
I am working on an assignment coding my first page and I am stuck! I had to take a screenshot of a webpage, place it in Illustrator and overlay it with a grid layout. Then I am coding it in Aptana and viewing it in Firefox. This is the layout:
I started with some similar code we used for another project. I am using section & aside classes of .col1, .col2, .col3 to make the columns & margin/padding of the layout. In .col1 I wanted a column of 112 px w/ background color: rgb(126,208,224) w/ 48px padding/margin to left to place photo and 2 lines of text. In .col2 I wanted a text column of 464px w/ 48px padding/margin to left & right. In .col3 I wanted a text column of 240px w/ 48px padding/margin to right.
-
Why is .col1 to the far right w/ no background color, .col2 to far left, & .col3 in middle?
-
I wanted to get rid of the footer, if I do the body of background: #fff; goes away. How can I remedy this?
fixed layout aside, article, section, header, footer, nav { display: block; } div, section, article, h1, h2, h3, p { margin: 0; padding: 0; } html, body { margin: 0; padding: 0; } html { background: rgb(206, 193, 167); } body { background: #fff; font: 100% 'Open Sans', Arial, Helvetica, sans-serif; width: 960px; height: 100%; margin: 0 auto 2em; } /*layout*/ header { background:rgb(0,114,143); margin-bottom: 16px; height: 48px; padding: 36px 0 0 36px; }.col1 {
float: left;
padding-left: 48px;
width: 112px;
background:rgb(126,208,224);}
.col2 {
float: left;
padding-right: 48px;
padding-left: 48px;
width: 464px;
}
.col3 {
float: left;
padding-right: 48px;
width: 112px;
font-size: 140%;
line-height: 1.6;
}
footer {
height: 80px;
clear: both;
background-color: rgb(100,98,102);
}
/typography/p {
font-weight: 300;
font-size: 1em;
line-height: 1.5;
margin-bottom: 1em;
}My father was a St. Bernard, my mother was a collie, but I am a Presbyterian. This is what my mother told me, I do not know these nice distinctions myself. To me they are only fine large words meaning nothing.
My mother had a fondness for such; she liked to say them, and see other dogs look surprised and envious, as wondering how she got so much education. But, indeed, it was not real education; it was only show: she got the words by listening in the dining-room and drawing-room when there was company, and by going with the children to Sunday-school and listening there; and whenever she heard a large word she said it over to herself many times, and so was able to keep it until there was a dogmatic gathering in the neighborhood, then she would get it off, and surprise and distress them all, from pocket-pup to mastiff, which rewarded her for all her trouble.
If there was a stranger he was nearly sure to be suspicious, and when he got his breath again he would ask her what it meant. And she always told him. He was never expecting this but thought he would catch her; so when boshe told him, he was the one that looked ashamed, whereas he had thought it was going to be she.
The others were always waiting for this, and glad of it and proud of her, for they knew what was going to happen, because they had had experience.
With a view to action experience seems in no respect inferior to art, and men of experience succeed even better than those who have theory without experience. (The reason is that experience is knowledge of individuals, art of universals, and actions and productions are all concerned with the individual; for the physician does not cure man, except in an incidental way, but Callias or Socrates or some other called by some such individual name, who happens to be a man.
Thank You!!!