CSS Hover color

CSS Hover color
0

#1
a:hover { color: #000; }

CatPhotoApp

what’s wrong with this code?


#2

Your syntax is absolutely fine. Can you send full CSS code to analyze what’s wrong with it?


#3

The code editor has a CSS rule to style all a tags black. Add a rule so that when the user hovers over the a tag, the color is blue.
THIS IS THE QUESTION


#4

It seems like you have the wrong color?

a:hover { color: blue; }

Is this the problem?


#5

Hi

a:hover { color: #000; } this will turn color black on hover - #000 is black.
So your code probably is changing text from black to black, not blue.

Because your code is not formatted for markdown we cannot see most of it. Your <a> tag appears as a link to a cat photo. You can wrap code in backticks or select the code button </> in toolbar above to format as computer code.

Here is the code editor for that challenge formatted as code.

<style>
  a {
    color: #000;
  }

</style>
<a href="http://freecatphotoapp.com/" target="_blank">CatPhotoApp</a>

Including the link to the challenge helps immensely when asking for assistance.
Here is the link to the challenge
https://learn.freecodecamp.org/responsive-web-design/applied-visual-design/adjust-the-hover-state-of-an-anchor-tag

I believe that if you use the ‘ask for help’ button on the challenge page most of this will done for you automatically. A topic will be opened in the correct forum with the link to your challenge included.
image


#6

it’s still doesn’t work. It says this;
The anchor tag should have a color of blue on hover.


#7

Can you copy and paste your entire solution so that everyone can see it? Be sure to format it as computer code or we won’t be able to see most of it


#8

Thank you. I got fix it

Result.

CatPhotoApp

cat photos


#9

I put the same code the guy in the top did


#10

Alphaleo, Yes, thank you so much.


#11

I’ve actually got the answer,

It asked me to put the both black and blue, but I missed that I gotta put the hover different place,
The answer is this:
a {
color: #000;
a:hover {
color: blue;
}
}