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 Flexbox Layout Flexbox Layout Challenge

Flexbox [Solved]

Hi, I am stuck on a flexbox challenge and have been so for the last twenty minutes now.The question calls for me to to reverse the column order by giving secondary the flexbox property and value that moves it to the beginning of the row. Thank you in advance for any assistance.

Here is the code:

@media (min-width: 611px) {

    /* Complete the challenge by writing CSS below */
.main-nav { display: flex; }
.main-nav li { flex-grow: 1; }

.content-row { display: flex; }


.secondary {display: flex;  -webkit-order: 1;}

}

I finally got it, sheesh. Here is the solution: .secondary { -webkit-order: 1;}

Kevin Fitzhenry
Kevin Fitzhenry
30,096 Points

How is the solution different from the code in the screen shot?

7 Answers

The answer is below but the solution is not obvious. Hope this helps others.

.secondary { -webkit-order: 1;}
carl simpson
carl simpson
Courses Plus Student 15,941 Points

he refers to adding in the -webkit-order at the very last point in the video , its just not obvious you have to put it in straight away , glad you figured it out

Zack Gehin
Zack Gehin
520 Points

Carl, thank you for the response. My syntax was spot on, especially since I caved in and googled flexbox syntax and utilized copy and paste...

The correct answer is -1, at least, this is what allowed me to pass with the webkit. Even then, this answer isn't exactly correct because the lesson explains the industry acceptable process as using order: AND -webkit-order: plus IE which is -ms.

I'm not sure why this lesson would only use webkit as this is not cross-browser functional... Or is it now? Care to elaborate? I feel this will continue to cause frustration for others.

Thank you, Zack

carl simpson
PLUS
carl simpson
Courses Plus Student 15,941 Points

hey , the answer is in there ... rewatch the video .. i got stuck on the same bit myself but off the top of my head cant remember what it is :D

if its the last question , check your syntax on the .secondary class

Zack Gehin
Zack Gehin
520 Points

Eh, I am stuck on this too... -webkit-order: 1; AND oder: 1; do not work -_-. I think there is a bug in this quiz.

carl simpson
PLUS
carl simpson
Courses Plus Student 15,941 Points

Hey Zack, this is tricky to pass as you need the syntax to be bang on .. .secondary { -webkit-order: 1;} .. to pass you need this and check your previous code ..

Kevin Fitzhenry
Kevin Fitzhenry
30,096 Points

For others that are stuck on this still,

You need to remove- display: flex; and add order: 1;