Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS CSS Layout Basics Page Layout with the Float Property The Float Challenge Solution

Nishay Madhani
Nishay Madhani
15,456 Points

How did i get it wrong?

what i did was float one to the left and the other one to the right and give them a width of 40 and 6 but what happened was that they were floating on each side but not in the same line can you please help me fix the error or tell me where i went wrong

your help will be appreciated. THANK YOU

() .primary { () float:right;() width:60%;() () margin-right:10px;() () padding-left:10px;v() () padding-right:12px() ; () color:green;() } .secondary { () float:left;() width:40%;() () margin-left:10px;() () padding-left:10px;() () padding-right:12px;() () }(```)

Mark Pryce
Mark Pryce
8,804 Points

Could you post your code or a screen shot? Would help a ton to find the issues :)

3 Answers

Please include a screenshot or include the code in the comment. That way other users can help you

Nishay Madhani
Nishay Madhani
15,456 Points

.primary { float:right; width:60%; margin-right:10px; padding-left:10px; padding-right:12px; color:green; } .secondary { float:left; width:40%; margin-left:10px; padding-left:10px; padding-right:12px;

Ok thanks. I will try to find the error!

Hmm... Maybe you are missing a closing curly brace }.