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

CSS CSS Layout Techniques Positioning Schemes Positioning Schemes Challenge

Dustin Morris
Dustin Morris
8,715 Points

During the positioning schemes challenge in task four, I get an error suggesting that task 1 is no longer true. Why?

Upon returning to task 1 the code passes without changes. Each task back up to four passes, but four still returns that it is causing task 1 to fail. Is this an error?

Task 4: "Establish another relative positioning context in content-row, then set the position of col so that both columns are absolutely positioned inside the row."

My code: .main-header, .content-row { position: relative; }

.main-logo, .main-nav, .primary-col, .secondary-col { position: absolute; }

.main-logo { top: 25px; left: 25px; }

.main-nav { bottom: 30px; right: 25px; }

Link: http://teamtreehouse.com/library/css-layout-techniques/positioning-schemes/positioning-schemes-challenge

3 Answers

Wayne Priestley
Wayne Priestley
19,579 Points

Hi Dustin,

Your code looks like this:

.main-header, .content-row { position: relative; }

.main-logo, .main-nav, .primary-col, .secondary-col { position: absolute; }

.main-logo { top: 25px; left: 25px; }

.main-nav { bottom: 30px; right: 25px; }
<div class="content-row">
   <div class="primary col">

I think you got a bit ahead of yourself, the question asks you to give the col a position of absolute, you've given the primary-col a position of absolute.

There is NO primary-col or secondary-col there is a class="primary col" and a class="secondary col" these do not mean one is a primary-col as primary and col are two separate classes.

Hope Ive explained that so you can understand me.

A clue on how to fix this is in the first paragraph I wrote.

Please just ask if you need more help or a better explanation.

Dustin Morris
Dustin Morris
8,715 Points

Right, I saw that and had changed them to "primary-col" and "secondary col" in the HTML, but after posting realized that I took two classes and married them into one. Either way, that mistake was irrelevant to the problem I was having. The first task only asked that I make .main-header relative. I am really not sure what happened, but as I said in my comment, once I tried it again, using the same code it worked. The next step required me to fix the .col class and .primary and .secondary classes.

Thanks for your help.

Dustin Morris
Dustin Morris
8,715 Points

Must have been a bug. After submitting this post, I went and tried again. By copy/pasting into the task, it passed. Thanks anyway.

Wayne Priestley
Wayne Priestley
19,579 Points

No probs Dustin,

These sort of bugs do pop up from time to time, frustrating I know but you did the right thing by posting your code when asking for help, Thanks!

Dustin Morris
Dustin Morris
8,715 Points

Yeah, Trying to get help with Linux builds and the forums that go with that teaches you always include your code. Though I am not certain of how to separate it in a comment like you did in your comment.

Wayne Priestley
Wayne Priestley
19,579 Points

There is a markdown cheatsheet, at the near the bottom of the page its in bold text.

Here is a post on how to use markdown