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 CSS Layout Basics Page Layout with the Float Property The Float Challenge Solution

jiwan gurung
jiwan gurung
4,248 Points

is primary and col 2 different class?can you use more than one class in an element?

can you have more than 1 class in an element and are they separted by space?

3 Answers

Recep Onalan
Recep Onalan
15,541 Points

Yes you can use unlimited classes in one element. Primary is a color class in bootstrap which color is blue. col2 is about the size of its largeness in the 12 col grid system

Emmanuel Molina
Emmanuel Molina
9,268 Points

You can have multiple class in an element if you use a space between them.

For example class="one two three four five".

If you use "-" instead you create one class with a long name.

For example class="this-is-only-one-class"

Adam Maley
Adam Maley
5,946 Points

Was this mentioned in previous videos? I feel like I did not learn this. I keep typing ".primary col { }" and ".secondary col" to select the separate columns then floating them separately to the left and the right.