' . __( 'Sticky', 'aguafuerte' ) . '';
}
// Set up and print post meta information.
// Translators: there is a space after "By".
print(__('By ', 'aguafuerte'));
printf( '%2$s ',
esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ),
get_the_author()
);
printf( '%3$s ',
esc_url( get_permalink() ),
esc_attr( get_the_date( 'c' ) ),
esc_html( get_the_date() )
);
}
endif;
if ( ! function_exists( 'aguafuerte_entry_header') ):
/**
* Print HTML with the entry header
*
* @since Aguafuerte 1.0.2
*/
function aguafuerte_entry_header(){ ?>
0' . __('No comments on ', 'aguafuerte') . get_the_title() . ' ',
// Translators: there is a space after "on.
'1 ' . __('Only one comment on ', 'aguafuerte') . get_the_title() . ' ',
// Translators: there is a space after "on.
'% ' . __('% comments on ', 'aguafuerte') . get_the_title() . ' '
);
}
endif;
/**
* Prints Aguafuerte's custom logo markup.
*
* @since Aguafuerte 1.0.2
*
*/
function aguafuerte_custom_logo() {
$html = sprintf( '
%3$s %4$s ',
esc_url( home_url( '/' ) ),
esc_attr(wp_get_attachment_image_url(get_theme_mod('custom_logo'), 'full') ),
esc_html( get_bloginfo( 'name') ) ,
esc_html( get_bloginfo( 'description') ) );
return $html;
}
add_filter('get_custom_logo', 'aguafuerte_custom_logo');
if ( ! function_exists( 'aguafuerte_post_navigation' ) ) :
/**
* Prints the markup for the navigation between posts and changes the default strings of the_post_navigation().
*
* @since Aguafuerte 1.0.2
*/
function aguafuerte_post_navigation() {
the_post_navigation( array(
'prev_text' => ' ' .
'' . __( 'Previous post:', 'aguafuerte' ) . ' ' .
'%title ',
'next_text' => '%title ' .
'' . __( 'Next post:', 'aguafuerte' ) . ' ' .
' ',
) );
}
endif;
if ( ! function_exists( 'aguafuerte_blog_navigation' ) ) :
/**
* Applies the user's choice for navigation/pagination and changes the default strings in the_posts_navigation() and the_posts_pagination().
*
* @since Aguafuerte 1.0.2
*/
function aguafuerte_blog_navigation() {
$aguafuerte_theme_options = aguafuerte_get_options( 'aguafuerte_theme_options' );
if ( $aguafuerte_theme_options['blog_navigation'] == 'navigation' ) :
the_posts_navigation( array(
'prev_text' => ' '. __( 'Older articles', 'aguafuerte' ),
'next_text' => __( 'Newer articles', 'aguafuerte' ).' ',
) );
else:
the_posts_pagination( array(
'prev_text' => ' ' . __( 'Previous page', 'aguafuerte' ) . ' ',
'next_text' => '' . __( 'Next page', 'aguafuerte' ) . ' ',
'before_page_number' => '' . __( 'Page', 'aguafuerte' ) . ' ',
) );
endif;
}
endif;
if ( ! function_exists( 'aguafuerte_comments_navigation' ) ) :
/**
* Prints custom html markup for the_comments_navigation()
*
* @since Aguafuerte 1.0.2
*/
function aguafuerte_comments_navigation() {
the_comments_navigation( array(
'prev_text' => ' '. __( 'Older comments', 'aguafuerte' ),
'next_text' => __( 'Newer comments', 'aguafuerte' ) . ' ',
));
}
endif;
if ( ! function_exists( 'aguafuerte_archive_title' ) ) :
/**
* Filters the_archive_title()
*
* @since Aguafuerte 1.0.7
*/
function aguafuerte_archive_title( $title ) {
if ( is_category() ) {
$title = __( 'All articles in ', 'aguafuerte' ) . single_cat_title( '', false );
} elseif ( is_tag() ) {
$title = __( 'All articles about ', 'aguafuerte' ). ucfirst( single_tag_title( '', false ) );
} elseif ( is_author() ) {
$title = get_template_part( 'template-parts/author-bio' );
$title .= __( 'All articles by ', 'aguafuerte') . get_the_author();
}
return $title;
}
add_filter( 'get_the_archive_title', 'aguafuerte_archive_title' );
endif;
if ( ! function_exists( 'aguafuerte_excerpt_more' ) && ! is_admin() ) :
/**
* Replaces "[...]" (appended to automatically generated excerpts) with ...
* and a Continue reading link.
*
* @since Aguafuerte 1.0.2
*
* @param string $more Default Read More excerpt link.
* @return string Filtered Read More excerpt link.
*/
function aguafuerte_excerpt_more( $more ) {
if ( ! is_single() ) {
$link = sprintf( '%2$s ',
esc_url( get_permalink( get_the_ID() ) ),
/* Translators: %s: Name of current post */
sprintf( __( 'More', 'aguafuerte' ).' %s ', '' . get_the_title( get_the_ID() ) . ' ' )
);
return ' … ' . $link;
}
else{
return '. ';
}
}
add_filter( 'excerpt_more', 'aguafuerte_excerpt_more' );
endif;
/**
* Filter the except length to 20 characters.
*
* @param int $length Excerpt length.
* @return int (Maybe) modified excerpt length.
*/
function aguafuerte_excerpt_length( $length ) {
return 50;
}
add_filter( 'excerpt_length', 'aguafuerte_excerpt_length', 999 );
/**
* Filters the edit comment link.
*/
function aguafuerte_edit_comment_link() {
$text = __('Edit', 'aguafuerte');
$link = '';
return $link;
}
add_filter( 'edit_comment_link', 'aguafuerte_edit_comment_link' );