Skip to content
This repository was archived by the owner on May 23, 2018. It is now read-only.

Commit 6a5704a

Browse files
committed
Merge pull request #400 from lancewillett/master
Escape attribute text properly in `aria-label` attributes
2 parents d8e126b + 6b54caa commit 6a5704a

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

footer.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
<footer id="colophon" class="site-footer" role="contentinfo">
1616
<?php if ( has_nav_menu( 'primary' ) ) : ?>
17-
<nav class="main-navigation" role="navigation" aria-label="<?php _e( 'Footer Primary Menu', 'twentysixteen' ); ?>">
17+
<nav class="main-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Footer Primary Menu', 'twentysixteen' ); ?>">
1818
<?php
1919
wp_nav_menu( array(
2020
'theme_location' => 'primary',
@@ -25,7 +25,7 @@
2525
<?php endif; ?>
2626

2727
<?php if ( has_nav_menu( 'social' ) ) : ?>
28-
<nav class="social-navigation" role="navigation" aria-label="<?php _e( 'Footer Social Links Menu', 'twentysixteen' ); ?>">
28+
<nav class="social-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Footer Social Links Menu', 'twentysixteen' ); ?>">
2929
<?php
3030
wp_nav_menu( array(
3131
'theme_location' => 'social',

header.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646

4747
<div id="site-header-menu" class="site-header-menu">
4848
<?php if ( has_nav_menu( 'primary' ) ) : ?>
49-
<nav id="site-navigation" class="main-navigation" role="navigation" aria-label="<?php _e( 'Primary Menu', 'twentysixteen' ); ?>">
49+
<nav id="site-navigation" class="main-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Primary Menu', 'twentysixteen' ); ?>">
5050
<?php
5151
wp_nav_menu( array(
5252
'theme_location' => 'primary',
@@ -57,7 +57,7 @@
5757
<?php endif; ?>
5858

5959
<?php if ( has_nav_menu( 'social' ) ) : ?>
60-
<nav id="social-navigation" class="social-navigation" role="navigation" aria-label="<?php _e( 'Social Links Menu', 'twentysixteen' ); ?>">
60+
<nav id="social-navigation" class="social-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Social Links Menu', 'twentysixteen' ); ?>">
6161
<?php
6262
wp_nav_menu( array(
6363
'theme_location' => 'social',

0 commit comments

Comments
 (0)