-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfront-page.php
55 lines (48 loc) · 1.57 KB
/
front-page.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<?php
// Exit if accessed directly
if( !defined( 'ABSPATH' ) ) {
exit;
}
/**
* Site Front Page
*
* Note: You can overwrite front-page.php as well as any other Template in Child Theme.
* Create the same file (name) include in /responsive-child-theme/ and you're all set to go!
* @see http://codex.wordpress.org/Child_Themes and
* http://themeid.com/forum/topic/505/child-theme-example/
*
* @file front-page.php
* @package Responsive
* @author Emil Uzelac
* @copyright 2003 - 2014 CyberChimps
* @license license.txt
* @version Release: 1.0
* @filesource wp-content/themes/responsive/front-page.php
* @link http://codex.wordpress.org/Template_Hierarchy
* @since available since Release 1.0
*/
/**
* Globalize Theme Options
*/
$responsive_options = responsive_get_options();
/**
* If front page is set to display the
* blog posts index, include home.php;
* otherwise, display static front page
* content
*/
if( 'posts' == get_option( 'show_on_front' ) && $responsive_options['front_page'] != 1 ) {
get_template_part( 'home' );
}
elseif( 'page' == get_option( 'show_on_front' ) && $responsive_options['front_page'] != 1 ) {
$template = get_post_meta( get_option( 'page_on_front' ), '_wp_page_template', true );
$template = ( $template == 'default' ) ? 'index.php' : $template;
locate_template( $template, true );
}
else {
get_header();
get_template_part( 'template-parts/featured-area', $responsive_options['featured_area_layout'] );
get_sidebar( 'home' );
get_footer();
}
?>