Last active
October 13, 2015 01:10
-
-
Save reasonstousegenesis/9cafb5e1216efdb3a7c7 to your computer and use it in GitHub Desktop.
Check if the child theme is accessible with Genesis
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Paste the code BELOW this line into your child theme functions. | |
/** | |
* Check if the child theme is accessible with Genesis | |
* | |
* @author Reasons to Use Genesis | |
* @link http://reasonstousegenesis.com/genesis-a11y/ | |
*/ | |
add_action( 'genesis_entry_content', 'rtug_screen_reader_text' ); | |
function rtug_screen_reader_text() { | |
if ( genesis_a11y( 'screen-reader-text' ) ) // to check for screen reader support, argument is optional | |
echo '<p class="screen-reader-text">This text is intended only for users with vision impairments.</p>'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment