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

HTML How to Make a Website Styling Web Pages and Navigation Style the Image Captions

Conor Smith
Conor Smith
941 Points

Folks Im not getting any space between my images, and my facebook and twitter icons are th only images in th 2nd column

<!this is my section gallery>
      <section>
        <ul id="gallery">
          <li>
            <a href="https://www.youtube.com/watch?v=g_qOdiGjlbI&feature=youtu.be">
                <img src="img/themagician.png" alt="">
                <p>The Magician - A short student film we created for a group project</p>
            </a>
            <a href="https://www.youtube.com/watch?v=isbUaCRfGQ4">
                <img src="img/mygaffradio.png" alt="">
                <p>A short promotional film I created for my weekly radio show, "Mygaff Radio"</p>
            </a>
            <a href="https://vimeo.com/81592990">
                <img src="img/woodturn.png" alt="">
                <p>Experimentation with colour</p>
            </a>
            <a href="img/crumbies.png">
                <img src="img/crumbies.png" alt="">
                <p>Quick logo created by me for my partners cake business</p>
            </a>
            <a href="img/logo1.png">
                <img src="img/logo1.png" alt="">
                <p>logo I created for a new startup called Zoe Technologies</p>
            </a>
          </li>
        </ul>
      </section>
/*******************************************
here is my CSS
****************************************/

#gallery {
  margin: 0;
  padding: 0;
  list-style: none;

}

#gallery li {
  float: left;
  width: 45%;
  margin: 2.5%;
  background-color: #f5f5f5;
  color: #bdc3c7;

}

#gallery li a p {
  margin: 0;
  padding: 5%;
  font-size: 0.75em;
  color: #bdc3c7;

}

Any Ideas were I went wrong? What size should our Images be if we are adding in our own ones?

Cheers.

1 Answer

you should change the HTML so that each link is a list item and not one list item:

<ul id="gallery">
          <li>
            <a href="https://www.youtube.com/watch?v=g_qOdiGjlbI&feature=youtu.be">
                <img src="img/themagician.png" alt="">
                <p>The Magician - A short student film we created for a group project</p>
            </a>
            </li>
           <li>
            <a href="https://www.youtube.com/watch?v=isbUaCRfGQ4">
                <img src="img/mygaffradio.png" alt="">
                <p>A short promotional film I created for my weekly radio show, "Mygaff Radio"</p>
            </a>
            </li>

//ect...