<?php
/*
*  Template Name: Bridallist
*/
get_header();
?>

	<section class="uni-container">
        <?php if (have_posts()) : while (have_posts()) : the_post();
        $aPostCustom = get_post_custom( $post->ID );
        if ( !empty($aPostCustom['uni_bridallist_page_header_image'][0]) ) {
            $aPageHeaderAttachIds = explode(',', $aPostCustom['uni_bridallist_page_header_image'][0]);
            $aPageHeaderImage = wp_get_attachment_image_src( $aPageHeaderAttachIds[0], 'full' );
            $sPageHeaderImage = $aPageHeaderImage[0];
        } else {
            $sPageHeaderImage = get_template_directory_uri().'/images/placeholders/pageheader-classes.jpg';
        }
        ?>
		<div class="pageHeader" style="background-image: url(<?php echo esc_url( $sPageHeaderImage ); ?>);">
			<h1><?php the_title() ?></h1>
		</div>
		<div class="contentWrap">
            <div class="pagePanel clear">
                <div class="pageTitle"><?php esc_html_e('Bridal list', 'asana') ?></div>
            </div>

        <?php the_content() ?>

		</div>
        <?php endwhile; endif; ?>
	</section>

<?php get_footer(); ?>