functions.php
/**
 * Add classes to the blog list for styling.
 */
Add classes to the blog list for styling.
Add classes to the blog list for styling .
function vogue_add_blog_post_classes ( $classes ) {
	global $current_class;
	if ( is_home() || is_archive() || is_search() ) :
		$vogue_blog_layout = sanitize_html_class( 'blog-left-layout' );
		if ( get_theme_mod( 'vogue-blog-layout' ) ) {
		    $vogue_blog_layout = sanitize_html_class( get_theme_mod( 'vogue-blog-layout' ) );
		}
		$classes[] = $vogue_blog_layout;
		$classes[] = $current_class;
		$current_class = ( $current_class == 'blog-alt-odd' ) ? sanitize_html_class( 'blog-alt-even' ) : sanitize_html_class( 'blog-alt-odd' );
	endif;
	return $classes;
}
function vogue_add_blog_post_classes ( $ classes ) { global $ current_class ; if ( is_home ( ) || is_archive ( ) || is_search ( ) ) : $ vogue_blog_layout = sanitize_html_class ( 'blog-left-layout' ) ; if ( get_theme_mod ( 'vogue-blog-layout' ) ) { $ vogue_blog_layout = sanitize_html_class ( get_theme_mod ( 'vogue-blog-layout' ) ) ; } $ classes [ ] = $ vogue_blog_layout ; $ classes [ ] = $ current_class ; $ current_class = ( $ current_class == 'blog-alt-odd' ) ? sanitize_html_class ( 'blog-alt-even' ) : sanitize_html_class ( 'blog-alt-odd' ) ; endif ; return $ classes ; }
Add classes to the blog list for styling.
Add classes to the blog list for styling .