have_posts() ){ while ( $query->have_posts() ){ $query->the_post(); // classes $post_class = array('post-item','isotope-item','clearfix'); if( ! mfn_post_thumbnail( get_the_ID() ) ) $post_class[] = 'no-img'; if( post_password_required() ) $post_class[] = 'no-img'; $post_class[] = 'author-'. mfn_slug( get_the_author_meta( 'user_login' ) ); $post_class = implode(' ', get_post_class( $post_class )); // background color | Style - Masonry Tiles $bg_color = get_post_meta( get_the_ID(), 'mfn-post-bg', true ); if( $bg_color && $style == 'masonry tiles' ){ $bg_color = 'style="background-color:'. $bg_color .';"'; } $output .= '
'; // icon | Style == Masonry Tiles if( $style == 'masonry tiles' ){ if( get_post_format() == 'video' ){ $output .= ''; } elseif( get_post_format() == 'quote' ){ $output .= ''; } elseif( get_post_format() == 'link' ){ $output .= ''; } elseif( get_post_format() == 'audio' ){ // for future use $output .= ''; } else { $rev_slider = get_post_meta( get_the_ID(), 'mfn-post-slider', true ); $lay_slider = get_post_meta( get_the_ID(), 'mfn-post-slider-layer', true ); if( $rev_slider || $lay_slider ){ $output .= ''; } } } // date | Style == Timeline $output .= '
'. get_the_date() .'
'; // photo -------------------------------------------------------------------------- if( ! post_password_required() ){ if( $style == 'masonry tiles' ){ // photo | Style != Masonry Tiles $output .= '
'; $output .= '
'; $output .= get_the_post_thumbnail( get_the_ID(), 'full', array( 'class'=>'scale-with-grid', 'itemprop'=>'image' ) ); $output .= '
'; $output .= '
'; } else { // photo | Style == * // Post Image $post_format = mfn_post_thumbnail_type( get_the_ID() ); if( $images_only ){ $post_format = $images_only; } $output .= '
'; $output .= '
'; $output .= mfn_post_thumbnail( get_the_ID(), 'blog', $style, $images_only ); $output .= '
'; $output .= '
'; } } // desc --------------------------------------------------------------------------- $output .= '
'; $output .= '
'; // head ------------------------------------- $output .= '
'; // meta ------------------------------------- if( mfn_opts_get( 'blog-meta' ) ){ $output .= ''; } // .post-footer | Style == Photo if( $style == 'photo' ){ $output .= ''; } $output .= '
'; // title ------------------------------------- $output .= '
'; if( get_post_format() == 'quote' ){ // quote ---------------------------- $output .= '
'. get_the_title() .'
'; } elseif( get_post_format() == 'link' ){ // link ---------------------------- $output .= ''; $output .= ''; } else { // default ---------------------------- $output .= '

'. get_the_title() .'

'; } $output .= '
'; // content ------------------------------------- $output .= '
'. get_the_excerpt() .'
'; // .post-footer | Style != Photo, Masonry Tiles if( ! in_array( $style, array('photo','masonry tiles') ) ){ $output .= ''; } $output .= '
'; $output .= '
'; $output .= '
'; } } return $output; } }