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 Responsive Web Design and Testing Write CSS Media Queries

Aleksandar Stankovic
seal-mask
.a{fill-rule:evenodd;}techdegree
Aleksandar Stankovic
Python Development Techdegree Student 9,648 Points

Task 1 not working

In the task 1 I added CSS Media Queri, and did everything I should, but system is giving me an error. When I tried the same at workspace, it works just fine. I am pretty sure I typed everything correct since this is not a large code. Don't know if I am doing something wrong in here.

3 Answers

Hi Aleksandar,

The below code is what you should be looking for.

@media only screen and (min-width : 480px) {
  h1 {
    font-size: 2.5em;
  }
}

Thanks, Bradley

Aleksandar Stankovic
seal-mask
.a{fill-rule:evenodd;}techdegree
Aleksandar Stankovic
Python Development Techdegree Student 9,648 Points

Dear Bradley,

Thanks for the prompt reply. Seems like this code is giving me the same error as well. The only difference between your code and mine is that you added this ''only''. I did it without that code.

Did you place it at the end of the existing css?

If you put it at the beginning then the later css will have a chance to override it.

Aleksandar Stankovic
seal-mask
.a{fill-rule:evenodd;}techdegree
Aleksandar Stankovic
Python Development Techdegree Student 9,648 Points

By the way , this should be quite a simple task, since the code is working just fine in the workspace. I am really curious about this issue...

Hi Aleksander,

It's difficult without seeing the code, however I once had this issue and realised that I never included this tag in the <head> of my HTML.

<meta name="viewport" content="width=device-width" />

Maybe this will help.

Thanks, Bradley.

Aleksandar Stankovic
seal-mask
.a{fill-rule:evenodd;}techdegree
Aleksandar Stankovic
Python Development Techdegree Student 9,648 Points

Mr. Jason Anello was correct, that is the solution to this problem. Thanks a lot Jason, and thank you very much Bradley for trying to help me out. All the best to both of you.