Viewing File: /home/maglabs/luchiana/wp-content/themes/floria/front-page.php

<?php
/**
 * The Front Page template file.
 *
 * @package FLORIA
 * @since FLORIA 1.0.31
 */

get_header();

// If front-page is a static page
if ( get_option( 'show_on_front' ) == 'page' ) {

	// If Front Page Builder is enabled - display sections
	if ( floria_is_on( floria_get_theme_option( 'front_page_enabled', false ) ) ) {

		if ( have_posts() ) {
			the_post();
		}

		$floria_sections = floria_array_get_keys_by_value( floria_get_theme_option( 'front_page_sections' ) );
		if ( is_array( $floria_sections ) ) {
			foreach ( $floria_sections as $floria_section ) {
				get_template_part( apply_filters( 'floria_filter_get_template_part', 'front-page/section', $floria_section ), $floria_section );
			}
		}

		// Else if this page is a blog archive
	} elseif ( is_page_template( 'blog.php' ) ) {
		get_template_part( apply_filters( 'floria_filter_get_template_part', 'blog' ) );

		// Else - display a native page content
	} else {
		get_template_part( apply_filters( 'floria_filter_get_template_part', 'page' ) );
	}

	// Else get the template 'index.php' to show posts
} else {
	get_template_part( apply_filters( 'floria_filter_get_template_part', 'index' ) );
}

get_footer();
Back to Directory File Manager