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 trialZach Perry
1,303 PointsNeed help with personal project ...
I recently finish the How to Make a Website course, and I wanted to start practicing my new skills on a similar website to the one that was created throughout the How to Make a Website course. The end product of the course was creating a personal portfolio/gallery. I wanted to create a similar product, but for my schools journalism club. Here is what I came up with: http://imgur.com/vHHukkf . As you can see, the column order kind of collapsed. An image is barely showing at the bottom, I couldn't get the entire page. I even thought it would look cool to have a similar layout to how content is shown on Pinterest. The goal of my product is to show images, a headline below it, and below that ... a short description. You can click on the boxes to go to the articles. However, the problem at hand here is the differing sizes of the boxes and images throwing the order that I once had ... off. My code is almost exactly the same as the projects, just a colors and a couple things I changed. But I was wondering if someone could guide me in the direction I should go to add order, or at least a 'Pinterest like' layout of content. Hopefully this can become a learning experience for me in the end. Any help is greatly appreciated, thank you for your time
I had a great deal of time trying to paste the code onto this post, and it made the post extremely long. I just posted the code onto a public document, Google Docs : https://docs.google.com/document/d/1X7EUqNSsHDUSmmfKtXk3VW1yNs2XUSFYnpT-7z24iTo/edit?usp=sharing
I also, have it on a workspace: http://web-x03pgo6ate.treehouse-app.com/
2 Answers
Ashlynn Pai
11,679 PointsI hope I'm not off base here ... I haven't done much CSS in 3 months ...
I think for the layout in the How to Make a Website course to work the images are all the same size and they flow naturally when put into a list into the next row. If you want to make the images all different sizes but force them into columns you have to tell the CSS, "make 3 columns, stick these images in column 1, these in column 2, etc." Then the images in each column flow in their own column. Keep in mind that CSS won't change the proportions of your image so you may have to crop it beforehand.
You can float two columns left and one right like http://www.456bereastreet.com/archive/201012/how_to_create_a_3-column_layout_with_css/. Or use a grid system like Bootstrap and divide the grid into 3.
I think it's easier at first to do like Nick does and use all the same size images. Then with some confidence under your belt experiment with different layouts.
David Tonge
Courses Plus Student 45,640 PointsHey, I think I got the perfect plugin for what you need accomplished. http://isotope.metafizzy.co/ I once use it for my old portfolio. Scroll to the bottom for examples.
Chris Brame
Courses Plus Student 4,447 PointsChris Brame
Courses Plus Student 4,447 PointsIs there a way we can see a demo, or some code? Its hard to help you troubleshoot your layout without seeing where you might have gone wrong. It could be something as simple as a style set incorrectly.