D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
home
/
etb1lp46s9ed
/
public_html
/
a3legalservices.site
/
wp-content
/
themes
/
aeen
/
templates
/
Filename :
blog-grid.php
back
Copy
<?php /** * Template Name: Blog Grid * * @author RadiusTheme * @since 1.0 * @version 1.0 */ namespace radiustheme\aeen; use radiustheme\aeen\inc\RDTheme; use radiustheme\aeen\inc\Helper; use \WP_Query; ?> <?php get_header(); $thumb_size = 'aeen-homeblog1'; $post_class = '4'; $args = array( 'post_type' => "post", 'posts_per_page' => get_option('posts_per_page'), ); if ( get_query_var('paged') ) { $args['paged'] = get_query_var('paged'); } elseif ( get_query_var('page') ) { $args['paged'] = get_query_var('page'); } else { $args['paged'] = 1; } $query = new WP_Query( $args ); global $wp_query; $wp_query = NULL; $wp_query = $query; ?> <!--=====================================--> <!--= Blog Start =--> <!--=====================================--> <section class="blog-wrap-layout2"> <div class="container"> <div class="row"> <?php if( have_posts() ) : while ( have_posts() ) : the_post(); ?> <div class="col-lg-4 col-md-6 col-12 wow animated fadeInUp" data-wow-delay="0.2s"> <div class="blog-box-layout2"> <?php if( has_post_thumbnail( ) ) : ?> <div class="item-figure"> <a href="<?php the_permalink(); ?>"><?php the_post_thumbnail( $thumb_size ); ?></a> </div> <?php endif; ?> <div class="item-content"> <?php if( RDTheme::$options['blog_date'] ) : ?> <div class="item-date"> <div class="item-day"><?php echo get_the_time( 'd' ); ?></div> <div class="item-month"><?php echo get_the_time( 'M' ); ?></div> </div> <?php endif; ?> <h3 class="entry-title"><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h3> <ul class="entry-meta"> <?php if( RDTheme::$options['blog_author_name'] ) : ?> <li class="item-author"> <i class="far fa-user"></i> <?php the_author_posts_link(); ?> </li> <?php endif; ?> <?php if ( RDTheme::$options['blog_cats'] && has_category() ): ?> <li> <i class="fas fa-tags"></i> <?php the_category( ', ' ); ?> </li> <?php endif; ?> </ul> <p><?php echo wp_trim_words( get_the_content( ), '20', '...' ); ?></p> <a href="<?php the_permalink(); ?>" class="blog-btn"><?php esc_html_e( 'Read More', 'aeen' ); ?><i class="fas fa-angle-right"></i></a> </div> </div> </div> <?php endwhile; ?> <?php else:?> <?php get_template_part( 'template-parts/content', 'none' );?> <?php endif;?> <?php wp_reset_postdata(); ?> </div> <?php Helper::pagination(); ?> </div> </section> <?php get_footer(); ?>