• Resolved Distiple

    (@distiple)


    im using a twenty ten child theme on my site, http://wordsandmusic.me.
    For some reason, there is a large amount of empty space to the left (using a right to left language), with the skip to content link appearing after scrolling all the way to the left (im assuming that link is the reason for this empty space).

    Is there any way to remove this space (i have no problem with removing the link as well)?

    Thanks.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi Distiple,

    Skip to content links are there for users viewing the web via screen-readers. It is not recommended to delete or hide these links using CSS as this prevents some screen-readers from picking them up. They should instead be positioned off the page using CSS, so they are not visible but still accessible for screen-readers.

    The skip to content links are positioned to the far left of your page. Normally this wouldn’t prove a problem, but your site’s direction is set from right to left. Therefore, the skip to content links need to be positioned to the far right of your page.

    To do this, firstly find the following code in your (child theme) style.css file:

    .screen-reader-text {
    position: absolute;
    left: -9000px;
    }

    Change the “left” to “right” so that you’re left with:

    .screen-reader-text {
    position: absolute;
    right: -9000px;
    }

    This should solve your issue. Let me know if it helps!

    Thread Starter Distiple

    (@distiple)

    Wonderful, thank you so much.

    I didnt have this code in my child theme, so i had to edit in the parents css. What code can i add to the child that will override this?

    Thanks again!

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    .screen-reader-text {
     left: initial;
     right: -9000px;
    }
    Thread Starter Distiple

    (@distiple)

    Perfect. Thank you both.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Skip content link and vertical scroll bar’ is closed to new replies.