Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Understanding 4.1.3 - wrong id reference in anchors #465

Closed
audreymaniez opened this issue Aug 28, 2018 · 3 comments
Closed

Understanding 4.1.3 - wrong id reference in anchors #465

audreymaniez opened this issue Aug 28, 2018 · 3 comments
Assignees

Comments

@audreymaniez
Copy link

audreymaniez commented Aug 28, 2018

In the sentence "Examples of status messages are given in the section titled Status Message Examples below." Status Message is an anchor, but the wrong id is referenced "https://www.w3.org/WAI/WCAG21/Understanding/status-messages.html#status-examples"

Change
<a href="#status-examples">Status Message Examples</a>
To
<a href="#status-message-examples">Status Message Examples</a>

Same problem for the anchor Examples of Changes That Are Not Status Messages, wrong id.

Change
<a href="#excepted-examples">Examples of Changes That Are Not Status Messages</a>
to
<a href="#examples-of-changes-that-are-not-status-messages">Examples of Changes That Are Not Status Messages</a>

@awkawk
Copy link
Member

awkawk commented Aug 28, 2018

@michael-n-cooper either Master hasn't been rolled out so the published version is out of sync or the generator is overwriting ids.

In Master (line 36 of https://github.com/w3c/wcag/edit/master/understanding/21/status-messages.html):
<h3 id="status-examples">Status Message Examples</h3>

In the live site:

<section class="example" id="status-message-examples">
          <h3>Status Message Examples</h3>

@patrickhlauke
Copy link
Member

patrickhlauke commented May 23, 2019

i believe (though my xslt is a bit rusty) that it's the generator (probably base.xslt) explicitly creating ids based on the heading text and overriding the id attribute already in the markup. cleanest fix would likely be to modify the xslt if possible NOT to generate custom ids if the attribute is already present. /cc @michael-n-cooper

[second edit] the reason for this seems even more complex ... removing my incorrect guess

(and yes, funnily enough i came here because i was going to file an issue about those relative links in 4.1.3 understanding...)

@patrickhlauke
Copy link
Member

patrickhlauke commented May 23, 2019

even odder...in master, the understanding document has

<section class="example">
<h3 id="status-examples">Status Message Examples</h3>

(with the id on the <h3>) but in the ouput https://www.w3.org/WAI/WCAG21/Understanding/status-messages.html it has

<section class="example" id="status-message-examples">
<h3>Status Message Examples</h3>

(with the id stripped from the <h3> and the new id added to the <section>)

[edit] and after adding correct code fences to @awkawk's previous comment, i see that he saw the same oddness...apologies for rehashing the same thing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants