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 trialAnthony Bennett
2,262 Points2 columns for images
My images seem to not condense into 2 columns even though my code is exact to the teacher. Are my images the wrong size? How do I get my images with the current size of 1024x768 to follow this design?
6 Answers
Mario Mitchell
18,789 Pointsmisspelled gallery galley ;) yeah the misspellings are 90 of my errors and I hate it because when you glance at the code everything looks right!
Mario Mitchell
18,789 Pointsalso your id's should have # in front of them like
gallery {
float: left; width: 45%; margin: 2.5%; background-color: #f5f5f5; color: #bdc3f7; }
Mario Mitchell
18,789 PointsCan't see your code but I believe you need to add style of float:left; to the the element that contains them. also max-width:100%;
Anthony Bennett
2,262 Pointsimg { max-width: 100%; }
gallery {
margin: 0;
padding: 0;
list-style: none;
}
galley li {
float: left;
width: 45%;
margin: 2.5%;
background-color: #f5f5f5;
color: #bdc3f7;
}
gallery li a p { margin: 0; padding: 5%; font-size: 0.75em; color: #fff }
I also properly added the id "gallery" to the ul in the html too. I thought I followed along exactly
Anthony Bennett
2,262 Pointswow good catch! I can't believe it. I spend over an hour looking at my code before starting this discussion! Thanks for the help and feedback!
Mario Mitchell
18,789 PointsNo problem, glad I was able to help.