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
Ron B.
1,497 PointsNeed Help With "Code Challenge: Using Classes"
So here is my source:
can anyone please tell me what i am doing wrong..
5 Answers
James Barnett
39,199 Points@Jodi -
Step 1) Start back at the beginning with this code
<div id="featured-cupcake">
<h2>Cupcake of the Week</h2>
<img src="img/featured-cupcake.jpg">
</div>
Step 2) Create a div with the classes container & clearfix
Step 3) Add a closing div tag so encloses the div with the ID of featured-cupcake
Step 4) Add the classes grid_5 & omega to the existing div which has an ID of featured-cupcake
James Barnett
39,199 PointsThe instructions for reference:
Add a 'div' around the 'featured-cupcake' element and give it the classes 'container' and 'clearfix'.
This is the relevant code ...
<div id="featured-cupcake">
<h2>Cupcake of the Week</h2>
<img src="img/featured-cupcake.jpg">
</div>
What this means is ...
- Create a new
divwhich wraps around thefeature-cupcakediv - Add
container&clearfix - Don't forget to close your new
div
Remember: to read the instructions closely and only write code required to complete that specific task.
For future reference it's easier if you create a "working" example using codepen.io.
Ron B.
1,497 Pointswhere my issue lies is "Add the classes 'grid_5' and 'omega' to the 'featured-cupcake' element."
Ron B.
1,497 PointsThank you so much james. That was a HUGE road block.
James Barnett
39,199 Points@Jodi - You are very welcome.