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 trialRobert Carpenter
Courses Plus Student 1,181 PointsMy images do not contain a space between them.
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>Robert Carpenter| Software Developer</title> <link rel= "stylesheet" href="css/normalize.css"> <link href='https://fonts.googleapis.com/css?family=Droid+Sans:400,700|Droid+Serif|Karla:700italic,700' rel='stylesheet' type='text/css'> <link rel= "stylesheet" href="css/style.css"> </head> <body> <header> <a href="index.html" id="logo"> <h1>Robert Carpenter</h1> <h2>Software Developer</h2>
</a>
<nav>
<ul>
<li><a href="index.html" class="Opened">Portfolio</a></li>
<li><a href="about.html" >About</a></li>
<li><a href="contact.html" >Contact</a></li>
</ul>
</nav>
</header>
<div id="wrapper">
<section>
<ul id="gallery">
<li>
<a href="img/numbers-01.jpg">
<img src="http://cdn1.theodysseyonline.com/files/2015/12/04/635848374574160134-920671144_zona.jpg" alt="My Birthplace">
<p>My Birthplace</p></a>
</li>
<li>
<a href="http://s3-origin-images.politico.com/2013/05/21/130521_fort_jackson_army2_ap_328.jpg">
<img src="http://s3-origin-images.politico.com/2013/05/21/130521_fort_jackson_army2_ap_328.jpg" alt="Where I developed my keen mind">
<p>Where I Developed My Keen Mind</p>
</a>
</li>
<li>
<a href="img/numbers-06.jpg">
<img src="http://1.bp.blogspot.com/-6-kzcjO-i40/Uaxm7Plzn5I/AAAAAAAADT4/OpOEhFH1eJU/s1600/Cochembridgeview.jpg" alt="Why I learned German">
<p>Why I learned German</p>
</a>
</li>
<li>
<a href="img/numbers-09.jpg">
<img src="http://projects.mindtel.com/2005/03.iraq/soldiers-pics/iraq-palaces/Bldg%2045,%20BIAP%20from%20roof.JPG" alt="Where I learned to Serve">
<p>Where I learned to Serve</p>
</a>
</li>
<li>
<a href="img/numbers-12.jpg">
<img src="http://bosworthsteel.com/wp-content/uploads/2014/08/Hospital-Steel-Project_Fort-Hood-Carl-Darnall_Bosworth-Steel-Erectors_HKS_11-536x345.jpg" alt="Where My Son Was Born">
<p>Where My Son Was Born</p>
</a>
</li>
</ul>
</section>
</div>
<footer>
<a href="http://www.twitter.com"><img src="img/twitter-wrap.png" alt="Twitter Logo"></a>
<a href="http://www.facebook.com"><img src="img/facebook-wrap.png" alt="Facebook Logo"></a>
<p> © 2016 Carpenter Concepts, LLC</p></footer>
</body> </html>
CSS
/**************************************************************************************************** GENERAL ORANGE= #ff3300; BLACK= #000; GREY= #bfbfbf WHITE= fff ****************************************************************************************************/
a { text-decoration: none; }
wrapper {
max-width: 940px; margin: 0 auto; padding: 0 5%; }
body { font-family: 'Droid Serif', sans-serif; }
img { max-width: 100%;
}
/**************************************************************************************************** HEADING **************************************************************************************************/ / Orange Header */
logo {text-align: center;
margin: 0; } header { border-bottom-width:5px; }
h1 { font-family: 'Droid Serif', sans-serif; margin: 20px 0; font-size: 1.75em; font-weight: normal; }
h2 { font-size: 1em; margin: -15px 0 0; font-weight: normal; }
/**************************************************************************************************** NAVIGATION ***************************************************************************************************/ / nav background for mobile */
nav { text-align: center; padding: 10px 0 0; margin: 20px 0 0; }
nav { background:#ff3300; } /* nav link */
nav a, nav a:visited { color:#fff; }
/* selected nav link */ nav a.Opened, nav a:hover { color:#ffbf00; }
/**************************************************************************************************** FOOTER ***************************************************************************************************/
footer {
font-size: 0.75em;
text-align: center;
clear:both;
padding-top; 50px;
color: #ccc;
}
/*************************************************************************************************** Page: Profile ***************************************************************************************************/
gallery {
margin: 0 0; padding 0 0; list-style: none; background-color:#bfbfbf;
}
gallery li {
float:left; width:45%; margin:2.5% background-color:#bfbfbf; color:#f5f5f5; }
/**************************************************************************************************** COLOR ***************************************************************************************************/ / Site Body*/ body { background-color:#fff; color: #aaa; }
a { color:#ff3300; border-color:#bfbfbf; }
header { border-color:#ff3300; background:#bfbfbf; }
/* Facebook and Twitter Text */ h1, h2 { color:#fff; }
2 Answers
Ben Ragsdale
14,187 PointsYou are missing a semi-colon after 'margin:2.5%'
You wrote:
gallery li {
float:left; width:45%; margin:2.5% background-color:#bfbfbf; color:#f5f5f5; }
It should be:
gallery li {
float:left; width:45%; margin:2.5%; background-color:#bfbfbf; color:#f5f5f5; }
It may help to put each css rule on its own line, so it is easier to troubleshoot in the future:
gallery li {
float:left;
width:45%;
margin:2.5%;
background-color:#bfbfbf;
color:#f5f5f5;
}
Miguel de Luis Espinosa
41,279 PointsYou probably want to copy your css as code, because the site is thinking that you # characters are headings :)
Robert Carpenter
Courses Plus Student 1,181 PointsRobert Carpenter
Courses Plus Student 1,181 PointsThank you for pointing out the problem in a way that required me to figure it out. It is amazing how one semicolon can change a web page but not the meaning of a page in a book.