post_parent ) : get_adjacent_post( false, '', true );
$next = get_adjacent_post( false, '', false );
if ( ! $next && ! $previous )
return;
}
if ( $wp_query->max_num_pages < 2 && ( is_home() || is_archive() || is_search() ) )
return;
$nav_class = ( is_single() ) ? 'post-navigation' : 'paging-navigation';
?>
' . __( 'Sticky', 'mckinley' ) . '';
if ( ! has_post_format( 'link' ) && 'post' == get_post_type() )
mckinley_entry_date();
// Translators: used between list items, there is a space after the comma.
$categories_list = get_the_category_list( __( ', ', 'mckinley' ) );
if ( $categories_list ) {
echo '' . $categories_list . '';
}
/* translators: used between list items, there is a space after the comma */
the_tags( '', esc_html__( ', ', 'mckinley' ), '' );
// Post author
if ( 'post' == get_post_type() ) {
printf( '%3$s',
esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ),
esc_attr( sprintf( __( 'View all posts by %s', 'mckinley' ), get_the_author() ) ),
esc_html( get_the_author() )
);
$format = get_post_format();
if ( $format ) {
if ( $format == "audio" ) {
$format_icon = "audio";
}
else if ( $format == "aside" ) {
$format_icon = "aside";
}
else if ( $format == "gallery" ) {
$format_icon = "gallery";
}
else if ( $format == "image" ) {
$format_icon = "image";
}
else if ( $format == "link" ) {
$format_icon = "link";
}
else if ( $format == "quote" ) {
$format_icon = "quote";
}
else if ( $format == "status" ) {
$format_icon = "status";
}
else if ( $format == "video" ) {
$format_icon = "video";
}
else {
$format_icon = "standard";
}
printf( '%3$s',
$format_icon,
esc_url( get_post_format_link( $format ) ),
get_post_format_string( $format )
);
}
}
}
endif;
if ( ! function_exists( 'mckinley_entry_date' ) ) :
/**
* Prints HTML with date information for current post.
*
* Create your own mckinley_entry_date() to override in a child theme.
*
* @since McKinley 1.0
*
* @param boolean $echo Whether to echo the date. Default true.
* @return string The HTML-formatted post date.
*/
function mckinley_entry_date( $echo = true ) {
if ( has_post_format( array( 'chat', 'status' ) ) )
$format_prefix = _x( '%1$s on %2$s', '1: post format name. 2: date', 'mckinley' );
else
$format_prefix = '%2$s';
$date = sprintf( '',
esc_url( get_permalink() ),
esc_attr( sprintf( __( 'Permalink to %s', 'mckinley' ), the_title_attribute( 'echo=0' ) ) ),
esc_attr( get_the_date( 'c' ) ),
esc_html( sprintf( $format_prefix, get_post_format_string( get_post_format() ), get_the_date() ) )
);
if ( $echo )
echo $date;
return $date;
}
endif;