';
}
return $links;
}
/**
* Add body class for blog
*
* @param $classes
*
* @return array
*/
public function body_classes( $classes ) {
$blog_layout = get_theme_mod( 'blog_layout', 'grid' );
// Blog page
if ( static::is_blog() && 'grid' == $blog_layout ) {
$classes[] = 'shapla-blog-grid';
}
return $classes;
}
/**
* Filters the number of words in an excerpt.
*
* @return int
*/
public function excerpt_length() {
$excerpt_length = get_theme_mod( 'blog_excerpt_length', 20 );
return absint( $excerpt_length );
}
/**
* Filters the string in the "more" link displayed after a trimmed excerpt.
*
* @return string
*/
public function excerpt_more() {
return sprintf( '%1$s %3$s',
__( '...', 'shapla' ),
get_permalink( get_the_ID() ),
__( 'Read more', 'shapla' )
);
}
/**
* Get grid blog style
*/
public function loop_post() {
$blog_layout = get_theme_mod( 'blog_layout', 'grid' );
if ( 'grid' == $blog_layout ) {
$this->get_loop_post_for_grid();
return;
}
$this->get_default_loop_post();
}
/**
* Default loop post design
*/
public function get_default_loop_post() {
?>