Learn Accessibility by Building a Quiz - Step 46

Tell us what’s happening:

I have honestly looked at like all of the similar questions but they all have the same code as me even after they fix it , so I’m not sure what I am doing wrong. All help will be great! thanks!

Your code so far

<!-- file: index.html -->

/* file: styles.css */
/* User Editable Region */

li a {
  color: #003366:
}

/* User Editable Region */

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36

Challenge Information:

Learn Accessibility by Building a Quiz - Step 46

Hi @ghost_bentley ,

It says to change the color of all the anchors inside list item elements inside the list.

Line 38 as an example, is specifying list items inside ULs inside NAVs. Use this as a guide to be more specific. ie: nav > ul > li

Yours is just specifying anchors inside list items, but doesn’t specify list elements.

1 Like

So technically if you were trying to select (li) and (a) elements you would use this code in css:

li, a {}

But here it is asking you to “Change the font color of all the anchor elements within the list elements”, this is where CSS SELECTORS come into play like you used in a previous step with

nav > ul > li {}

You would just need to apply the same concept because you are trying to SPECIFICALLY select the element you want to style.

2 Likes

I was purposely avoiding giving the answer away, as I was told by moderators in my previous responses not to do that. Just a heads up.

2 Likes

thanks for the recommendations but i still cannot figure out how to do it, could you give me a little bit more explanation, obviously without giving the answer.

Firstly, we don’t end CSS statements in a colon. Semi-colons are allowed though.

After that, I would look for another color to use since there isn’t enough contrast between the text and the navbar.

3 Likes

Thank you guys so much all of the help it was super useful!! :innocent:

1 Like