>
1, 'post__not_in' => get_option( 'sticky_posts' ), 'p' => $p); } else if ($juniper_pp_toggle=='page') { $p=intval(juniper_get_option('fp_pp_banner_page')); $custom_args = array('posts_per_page' => 1, 'page_id' => $p); } } else { $custom_args = array('posts_per_page' => 1, 'post__not_in' => get_option( 'sticky_posts' )); } $custom_query = new WP_Query( $custom_args ); if ( $custom_query->have_posts() ) { while ( $custom_query->have_posts() ) { $custom_query->the_post(); $sub_title=trim(juniper_get_option('fp-pp-banner-sub-title-override')); if (empty($sub_title)) { $content = get_the_content(); $sub_title=wp_trim_words( $content , '5' ); } if ( has_post_thumbnail() ) { $thumb_id = get_post_thumbnail_id(); $thumb_url_array = wp_get_attachment_image_src($thumb_id); $thumb_url = $thumb_url_array[0]; if (!empty($thumb_url)) { $juniper_parallax="data-parallax='scroll' data-image-src='" . esc_url($thumb_url) . "' style='background: rgba(0, 0, 0, 0.35);'"; $parallax_active="parallax_active"; } } else { $section_bg=juniper_get_option('fp-banner-background-image'); if (!empty($section_bg)) { $juniper_parallax="data-parallax='scroll' data-image-src='" . esc_url($section_bg) . "' style='background: rgba(0, 0, 0, 0.35);'"; $parallax_active="parallax_active"; } else { $juniper_parallax="data-parallax='scroll' data-image-src='" . get_template_directory_uri() . "/assets/images/preview/sky.jpg' style='background: rgba(0, 0, 0, 0.35);'"; $parallax_active="parallax_active"; } } ?>
>
'); ?>
>