Fix Codesniffer errors.
This commit is contained in:
parent
b215eebe1e
commit
175524922c
17 changed files with 59 additions and 32 deletions
|
@ -4,13 +4,12 @@
|
|||
* http://codex.wordpress.org/Custom_Headers
|
||||
*
|
||||
* You can add an optional custom header image to header.php like so ...
|
||||
|
||||
*
|
||||
<?php if ( get_header_image() ) : ?>
|
||||
<a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home">
|
||||
<img src="<?php header_image(); ?>" width="<?php echo esc_attr( get_custom_header()->width ); ?>" height="<?php echo esc_attr( get_custom_header()->height ); ?>" alt="">
|
||||
</a>
|
||||
<?php endif; // End header image check. ?>
|
||||
|
||||
*
|
||||
* @package _s
|
||||
*/
|
||||
|
@ -46,7 +45,7 @@ function _s_header_style() {
|
|||
$header_text_color = get_header_textcolor();
|
||||
|
||||
// If no custom options for text are set, let's bail
|
||||
// get_header_textcolor() options: HEADER_TEXTCOLOR is default, hide text (returns 'blank') or any hex value
|
||||
// get_header_textcolor() options: HEADER_TEXTCOLOR is default, hide text (returns 'blank') or any hex value.
|
||||
if ( HEADER_TEXTCOLOR == $header_text_color ) {
|
||||
return;
|
||||
}
|
||||
|
@ -64,7 +63,7 @@ function _s_header_style() {
|
|||
clip: rect(1px, 1px, 1px, 1px);
|
||||
}
|
||||
<?php
|
||||
// If the user has set a custom color for the text use that
|
||||
// If the user has set a custom color for the text use that.
|
||||
else :
|
||||
?>
|
||||
.site-title a,
|
||||
|
@ -124,4 +123,4 @@ function _s_admin_header_image() {
|
|||
</div>
|
||||
<?php
|
||||
}
|
||||
endif; // _s_admin_header_image
|
||||
endif; // _s_admin_header_image
|
||||
|
|
|
@ -38,7 +38,7 @@ if ( version_compare( $GLOBALS['wp_version'], '4.1', '<' ) ) :
|
|||
|
||||
global $page, $paged;
|
||||
|
||||
// Add the blog name
|
||||
// Add the blog name.
|
||||
$title .= get_bloginfo( 'name', 'display' );
|
||||
|
||||
// Add the blog description for the home/front page.
|
||||
|
@ -47,7 +47,7 @@ if ( version_compare( $GLOBALS['wp_version'], '4.1', '<' ) ) :
|
|||
$title .= " $sep $site_description";
|
||||
}
|
||||
|
||||
// Add a page number if necessary:
|
||||
// Add a page number if necessary.
|
||||
if ( ( $paged >= 2 || $page >= 2 ) && ! is_404() ) {
|
||||
$title .= " $sep " . sprintf( esc_html__( 'Page %s', '_s' ), max( $paged, $page ) );
|
||||
}
|
||||
|
|
|
@ -19,9 +19,12 @@ function _s_jetpack_setup() {
|
|||
} // end function _s_jetpack_setup
|
||||
add_action( 'after_setup_theme', '_s_jetpack_setup' );
|
||||
|
||||
/**
|
||||
* Custom render function for Infinite Scroll.
|
||||
*/
|
||||
function _s_infinite_scroll_render() {
|
||||
while ( have_posts() ) {
|
||||
the_post();
|
||||
get_template_part( 'template-parts/content', get_post_format() );
|
||||
}
|
||||
} // end function _s_infinite_scroll_render
|
||||
} // end function _s_infinite_scroll_render
|
||||
|
|
|
@ -92,7 +92,7 @@ function _s_posted_on() {
|
|||
'<span class="author vcard"><a class="url fn n" href="' . esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ) . '">' . esc_html( get_the_author() ) . '</a></span>'
|
||||
);
|
||||
|
||||
echo '<span class="posted-on">' . $posted_on . '</span><span class="byline"> ' . $byline . '</span>'; // WPCS: XSS OK
|
||||
echo '<span class="posted-on">' . $posted_on . '</span><span class="byline"> ' . $byline . '</span>'; // WPCS: XSS OK.
|
||||
|
||||
}
|
||||
endif;
|
||||
|
@ -107,13 +107,13 @@ function _s_entry_footer() {
|
|||
/* translators: used between list items, there is a space after the comma */
|
||||
$categories_list = get_the_category_list( esc_html__( ', ', '_s' ) );
|
||||
if ( $categories_list && _s_categorized_blog() ) {
|
||||
printf( '<span class="cat-links">' . esc_html__( 'Posted in %1$s', '_s' ) . '</span>', $categories_list ); // WPCS: XSS OK
|
||||
printf( '<span class="cat-links">' . esc_html__( 'Posted in %1$s', '_s' ) . '</span>', $categories_list ); // WPCS: XSS OK.
|
||||
}
|
||||
|
||||
/* translators: used between list items, there is a space after the comma */
|
||||
$tags_list = get_the_tag_list( '', esc_html__( ', ', '_s' ) );
|
||||
if ( $tags_list ) {
|
||||
printf( '<span class="tags-links">' . esc_html__( 'Tagged %1$s', '_s' ) . '</span>', $tags_list ); // WPCS: XSS OK
|
||||
printf( '<span class="tags-links">' . esc_html__( 'Tagged %1$s', '_s' ) . '</span>', $tags_list ); // WPCS: XSS OK.
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -189,7 +189,7 @@ function the_archive_title( $before = '', $after = '' ) {
|
|||
$title = apply_filters( 'get_the_archive_title', $title );
|
||||
|
||||
if ( ! empty( $title ) ) {
|
||||
echo $before . $title . $after; // WPCS: XSS OK
|
||||
echo $before . $title . $after; // WPCS: XSS OK.
|
||||
}
|
||||
}
|
||||
endif;
|
||||
|
@ -216,7 +216,7 @@ function the_archive_description( $before = '', $after = '' ) {
|
|||
*
|
||||
* @param string $description Archive description to be displayed.
|
||||
*/
|
||||
echo $before . $description . $after; // WPCS: XSS OK
|
||||
echo $before . $description . $after; // WPCS: XSS OK.
|
||||
}
|
||||
}
|
||||
endif;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue