<?php
/**
 * The main template file
 *
 * This is the most generic template file in a WordPress theme
 * and one of the two required files for a theme (the other being style.css).
 * It is used to display a page when nothing more specific matches a query.
 * E.g., it puts together the home page when no home.php file exists.
 *
 * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
 *
 * @package echohealth
 */

get_header();
	$blog_post_style = get_query_var( 'blog_style');
	if(!$blog_post_style){
		$blog_post_style  = echohealth_get_options('blog_post_style');
	}
	if( $blog_post_style == 2 ) :
		$blog_post_style_name = 'grid';
	else :
		$blog_post_style_name = 'standard';
	endif;
	get_template_part('template-parts/blog-layout/blog-'. $blog_post_style_name );
get_footer();