Control where #content goes?

Hi, folx!

I’m using Accessibility Checker and have a “Broken Skip or Anchor Link” error on all of my pages, with the following affected code:

<a id="pojo-a11y-skip-content" class="pojo-skip-link pojo-skip-content" tabindex="1" accesskey="s" href="#content">Skip to content</a>

Indeed, when i navigate my screen with my tab key, i go somewhere not at the top of my content when hitting spacebar on the “Skip to content” option. Sometimes, i go to the middle of my page and sometimes to the very bottom.

How do i fix this? If it involves CSS, with which i have zero experience, the more details you can give about where i need to paste something, the less likely i’ll be to break something else. :slight_smile:

Thanks for any insight anyone has.

Hi Shannon,

Thanks for reaching out.
It is not very clear what exactly is happening at your place. Can you please share the page URL along with any video that helps us recognize the problem?

Thanks

Thanks, Tristup! Here’s a video that will hopefully help you see what’s going on: https://videos.files.wordpress.com/1LMTZZVW/skip-to-content-problem.mp4.

I’m also attaching two screenshots of the errors Accessibility Checker is giving me.

The “Full Documentation” button on the first screenshot goes here: https://equalizedigital.com/accessibility-checker/broken-skip-link/?utm_source=accessibility-checker&utm_medium=software&utm_term=broken_skip_anchor_link&utm_content=content-analysis&utm_campaign=wordpress-general&php_version=8.1.26&platform=wordpress&platform_version=6.4.2&software=free&software_version=1.6.10&days_active=20.

Let me know what other clarification i can provide.

Hello Shannon,

I have inspected the page and there is no element whatsoever on the page that has an ID of content. If you change the link to #cs-content, then it may work but this will display directly to the page content and not the title heading.

You may need to modify a template in your child theme to be able to accomplish this if you would like to choose the #content as the link.

You can check out this old thread as a reference on how to override a template.

Best Regards.

Thanks, ruenel. I’ll start working on trying to figure this out this weekend.

You are most welcome, Shannon.

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