Is this an id or?

I am trying to emulate a footnote/anchor on this page. It is at the bottom: http://type-a-file.com/#ems
It is ‘called’ in the paragraph with the big P: in the sentence: “The standard line-height online is something between 1.5 and 2.0 ems.[1]”

When I inspect both elements I think I understand that I am looking at an “anchor” <a href="#ems" class="superscript">1</a> which brings me to the bottom of the page where “ems” is used in the footnote. This is the code: <li id="ems">. But I can’t find the id in the style sheet referenced taf-seafarer-m.css. What am I missing?

Thanks in advance!

Pos

1 Like

Welcome to the forums, @posweyb.

When you post code on the forums, you need to format it so it will display correctly.

You can highlight your code, then use the </> button in the editor window, or you can place three backticks ``` (top left key on US/UK keyboards) on a line above your code, and three on a line below your code. I find this approach easier, but unfortunately some European and other keyboards don’t have that character. For inline code, a single backtick before and after the code section does the trick. smile

(I’ve edited your post for you.)

Hi,

If I understand the question. :slightly_smiling_face:

The ID works as an HTML target for the URL/#fragment.

The browser doesn’t read the CSS to find the ID, it reads the HTML.

2 Likes

The id is not used in the CSS as @Erik_J said above but is used as the target for an internal page link.

The css for the footnote at the bottom is controlled in the CSS by .footnote and .footnote li styles plus the .run-in class for the run in span.

The css for the superscript 1 link is controlled by the .superscript class in the css.

2 Likes

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.