twentyfifteen_excerpt_more

Replaces "[.

Description

(string) twentyfifteen_excerpt_more( $more ); 

..]" (appended to automatically generated excerpts) with ... and a Continue reading link.

Returns (string)

'Continue reading' link prepended with an ellipsis.

Parameters (1)

0. $more
The more.

Usage

  1. if ( !function_exists( 'twentyfifteen_excerpt_more' ) ) { 
  2. require_once '/inc/template-tags.php'; 
  3.  
  4. // The more. 
  5. $more = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = twentyfifteen_excerpt_more($more); 
  9.  

Defined (1)

The function is defined in the following location(s).

/inc/template-tags.php  
  1. function twentyfifteen_excerpt_more( $more ) { 
  2. $link = sprintf( '<a href="%1$s" class="more-link">%2$s</a>',  
  3. esc_url( get_permalink( get_the_ID() ) ),  
  4. /** translators: %s: Name of current post */ 
  5. sprintf( __( 'Continue reading %s', 'twentyfifteen' ), '<span class="screen-reader-text">' . get_the_title( get_the_ID() ) . '</span>' ) 
  6. ); 
  7. return ' … ' . $link;