From c7fdbb48eb5ce067b8348f59ccc5c3afe9383805 Mon Sep 17 00:00:00 2001 From: Laury GvR Date: Fri, 10 Nov 2017 14:22:42 -0500 Subject: [PATCH] Posts now also use the same header image as News --- functions.php | 5 +---- parts/header-meta.php | 2 +- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/functions.php b/functions.php index 092ae11..c815ab7 100644 --- a/functions.php +++ b/functions.php @@ -83,11 +83,8 @@ function glm_get_header() { if (has_post_thumbnail() && is_post_type('page')) { $image_data = wp_get_attachment_image_src(get_post_thumbnail_id(), "full"); echo ' style="background-image: url('.$image_data[0].');height:0;padding:0;padding-bottom:20%;background-position:center center;background-size: 100%;background-repeat:no-repeat;max-height: 300px;overflow-y: hidden; "'; - } else if(is_home()) { - echo ' style="background-image: url('.get_template_directory_uri().'/assets/slideshow-exterior-night.png);height:0;padding:0;padding-bottom:20%;background-position:center center;background-size: 100%;background-repeat:no-repeat;max-height: 300px;overflow-y: hidden;"'; - echo ' class="no-featured"'; } else if(is_post_type('post') ){ - echo ' style="background-image: url('.get_template_directory_uri().'/assets/blog-default.png);height:0;padding:0;padding-bottom:20%;background-position:center center;background-size: 100%;background-repeat:no-repeat;max-height: 300px;overflow-y: hidden;"'; + echo ' style="background-image: url('.get_template_directory_uri().'/assets/slideshow-exterior-night.png);height:0;padding:0;padding-bottom:20%;background-position:center center;background-size: 100%;background-repeat:no-repeat;max-height: 300px;overflow-y: hidden;"'; echo ' class="no-featured"'; } else if(!has_post_thumbnail() && is_post_type('page')){ echo ' style="background-image: url('.get_template_directory_uri().'/assets/page-default.png);height:0;padding:0;padding-bottom:20%;background-position:center center;background-size: 100%;background-repeat:no-repeat;max-height: 300px;overflow-y: hidden;"'; diff --git a/parts/header-meta.php b/parts/header-meta.php index 368ddcc..3696a02 100644 --- a/parts/header-meta.php +++ b/parts/header-meta.php @@ -2,7 +2,7 @@ <?php wp_title(); ?> - + -- 2.17.1