Should Adam's Greenworks get a scope?

Why didn’t we put 'Adam’s Greenwork under scope=col attribute?

Do you mean like this?

    <thead>
      <tr>
        <th scope="col">Company Name</th>
        <th scope="col">Number of Items to Ship</th>
        <th scope="col">Next Action</th>
      </tr>
    </thead>
3 Likes

yes, but just Adam’s Greenwork

We wouldn’t be assigning scope to a data cell. That is meant for THs, as shown above.

5 Likes

This really helped :slightly_smiling_face: :slightly_smiling_face: :slightly_smiling_face: :slightly_smiling_face: :slightly_smiling_face: :grinning: :grinning: :grinning:

2 Likes

Is this how we should have done it? I’ve done as following and it still worked.

<table> 
 <tr>
   <th>Company Name</th>
   <th>Number of Items to Ship</th>
   <th>Next Action</th>
 </tr>

Looks okay, but does it comply with the instructions? Don’t forget to close the TABLE. We see you have not declared a THEAD, or scope on the THs. Is that still to come in the instructions?

1 Like

Hi, I have tried to assign scope “row” or “col” for the

but it didnt make any different as below:
<th scope="row">Company Name</th>

<th scope="row">Number of Items to Ship</th>

<th scope="row">Next Action</th>

The THs are column headers so the scope should be col, not row

1 Like

Thanks a lot mtf for the above answer but why row or col usage didn’t make any different in web page I’m developing

The scope attribute is used by screen readers to enhance accessibility for visually impaired users.
So you won’t see any difference on your page, but a vision impaired person using a screen reader will benefit from proper usage of scope attribute.

So for table headings “scope” is set to “col”, and for “Adam’s Greenwork” it should be set to “row”

2 Likes

I’m sorry, I’m still confused about this particular subject. So I did Adam’s Greenworks and I’m struggling to fully understand the purpose of putting/not putting scope=“col” or scope=“row”. If scope attribute is for the visually impaired, what makes this correct/incorrect?

I’m confused,
wouldn’t the first three Headings: Company Name, Number of Items and Next Action be scope=“col”

and then Adam’s Greenworks shouldn’t be scoped as is not a table measuring two variables but just data.

Ok, I just looked it up and I think you are mixing rows ups with columns. The codecademy lesson is correct. Rows are arranged horizontally, according to differencebetween.net
Not sure about the following question, as I am very new at coding

Difference Between Rows and Columns

Is it really necessary to add a scope=column?

I remember reading something about multiple cells in a tr are automatically shown as columns next to each other.

Yes,as Far I know scope=“Column” must be added to the table heading(th) in the given practice section to indicate that this particular column represent this type of information.
But it works even without that scope attribute, because scope attribute is actually for screen readers,it do not make any visual changes to it.

1 Like