What's wrong with fcc

What's wrong with fcc
0

#1

I don’t know what i’m doing wrong here.
The challenge wants me to change cthe olor of #target1 to red and i did so but still can’t pass the test.

 $("#target1").css("color", "red");

#2

Which challenge are you working on?


#3

We don’t really have enough information to help you. Change the CSS of an Element Using jQuery does accept that as the solution if it’s in the correct place. Without the rest of your code, we can’t tell whether you may have an error outside of that single line. It could also be your browser. Are you by any chance using Edge, IE, or Safari as your browser? Free Code Camp has bee updated to use newer technologies. It makes the application much faster and it means that we can go much longer without having to do a huge migration like the recent one. However, Edge, Internet Explorer, and Safari are very bad about choosing not to adhere to standards and support new functionality in JS and CSS. Right now, that means that these browsers exhibit lots of unexpected behavior. If you become a web developer you will come to hate these browsers with every fiber of your being.


#4

@randelldawson

https://learn.freecodecamp.org/front-end-libraries/jquery/change-the-css-of-an-element-using-jquery/


#5
<script>
  $(document).ready(function() {
    $("#target1").css("color", "red");
  });
</script>

It changes the color but i can’t pass the challenge.
My browser is latest version of chrome.


#6

did you delete the rest of the code? You should leave the rest of the code alone. Just add your target1 line to it.


#7

@Tirjasdyn
I didn’t delete anything


#8

Here’s another error

something is wrong with

$('selector').css( );

#9

So it worked find when I pasted $("#target1").css(“color”, “red”); into the https://learn.freecodecamp.org/front-end-libraries/jquery/change-the-css-of-an-element-using-jquery/

For this challenge its a bit weird. You shouldn’t be using background-color, just background.