Help with Technical Documentation Page project

Hello
Please can someone help me identify what the problem in my code is?
I have run the tests, and I have two more problems to fix, but I don’t see what is wrong with my code

I’m supposed to have a <header> describing the topic of each section, and then also in each section, I should have an id which has the same name as the header.

I have done that, but it still says I haven’t done it.
This is what I have done

Is it because I did not write the code properly, or I haven’t done it at all and I’m just confused?

Check your last two section with id main-section,
they don’t have a header tag as there is in other.

1 Like

Hi @maameyaatwumasi, when a test fails click the red button to see which test(s) are failing and text to help you correct the issue. (Be sure and read more than just the first line of the failing message.)

The first failing message says;

The first element within each .main-section should be a <header> element which contains text that describes the topic of that section.
Not all elements with the class 'main-section' have a <header> element as a first element child : expected 6 to equal 8  
AssertionError: Not all elements with the class 'main-section' have a <header> element as a first element child : expected 6 to equal 8

From the second and third lines does your code meet this criteria?

Debugging the second failing message will be similar.

On a side note after looking at your code;

  • Keep all your styling external. Do not use in-line styling.
  • Don’t use the <br> element to force line breaks or spacing. That’s what CSS is for. And to help, nest multi-line <code> snippets in <pre> </pre> tags in HTML to preserve whitespace and line breaks.
    Or skip the pre element and do the following in CSS;
code {
white-space: pre-line;
}

Hope that helps.

1 Like