Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

CSS

Milton Centeno
PLUS
Milton Centeno
Courses Plus Student 7,940 Points

col CSS class in Layout Techniques

Greetngs, I'm still learning and this question is in regard to the CSS Layout Techniques project files 1-3. Can someone please explain the following class attribute with the col after the class name. <div class="primary-content col"> I've used it as an attribute for column width within tables or for the column width regarding the width of a text field or text area. But it used here like an additional css class. Yet the external css file has no col class. Thank you.

1 Answer

Jacob Miller
Jacob Miller
12,466 Points

Within the style.css file it has the following styling:

.col {
    padding: 20px;
}

and

.col {
    width: 30%;
    display: inline-block;
    margin-right: -5px;
    vertical-align: top;
}