$prehome_background_image = $prehome_background_image[0];
        $locations_logo = get_field('locations_logo');
        if (!empty($locations_logo)) {
            $locations_logo_alt = $locations_logo['alt'];
            $locations_logo_size = 'medium';
            $locations_logo_sized = $locations_logo['sizes'][$locations_logo_size];
            $locations_logo_width = $locations_logo['sizes'][$locations_logo_size . '-width'];
            $locations_logo_height = $locations_logo['sizes'][$locations_logo_size . '-height'];
        }
        ?>

        <a class="prehome__permalink" href="<?php 
        the_permalink();
        ?>
" <?php 
        tt_background_image($prehome_background_image);
        ?>
 >
            <?php 
        if (!empty($locations_logo)) {
            ?>
                <img class="prehome__title" src="<?php 
            echo $locations_logo_sized;
            ?>
" alt="<?php 
            echo $locations_logo_alt;
            ?>
" width="<?php 
            echo $locations_logo_width;
            ?>
" height="<?php 
Example #2
0
<body <?php 
body_class();
?>
>
<div id="page" class="feed site">
    <a class="skip-link screen-reader-text" href="#content"><?php 
esc_html_e('Skip to content', 'turn-the-table');
?>
</a>

<?php 
if ($header_logo) {
    ?>
    <div class="header-wrapper">
        <header id="masthead" class="site__header" role="banner" <?php 
    tt_background_image($header_background_image);
    ?>
 >
            <div class="site__header-inner">

                <div class="header__item site__description">
                    <?php 
    if (!empty($header_tagline)) {
        echo $header_tagline;
    }
    ?>

                    <?php 
    if (!empty($header_tagline_link)) {
        ?>
                        <a href="<?php 
    $message_image_width = $message_image['sizes'][$message_image_size . '-width'];
    $message_image_height = $message_image['sizes'][$message_image_size . '-height'];
}
$message_background_image = get_field('message_background_image');
$message_background_color = get_field('message_background_color');
?>


<section class="section section__message <?php 
echo hidden_class();
echo ' ';
echo alignment_class();
?>
" <?php 
tt_background_color($message_background_color);
tt_background_image($message_background_image);
?>
 >
    <div class="section__inner-wrapper">

        <?php 
if (!empty($message_image)) {
    ?>
            <div class="section__image-wrapper">
                <img class="message__image section__image" src="<?php 
    echo $message_image_thumb;
    ?>
" alt="<?php 
    echo $message_image_alt;
    ?>
" width="<?php 
    <?php 
}
?>


    <!-- POSTS-SECTION -->
    <?php 
// loop through menu titles for toggle buttons
$loop = new WP_Query(array('post_type' => 'post', 'meta_query' => array(array('key' => '_wp_page_template', 'value' => 'template_posts.php')), 'tax_query' => $query_array));
$loop2 = new WP_Query(array('post_type' => 'post', 'posts_per_page' => 3, 'tax_query' => $query_array));
$loop3 = new WP_Query(array('post_type' => 'page', 'tax_query' => $query_array, 'post_parent' => $postParent->ID, 'meta_query' => array(array('key' => '_wp_page_template', 'value' => 'template_posts.php'))));
if ($loop2->have_posts()) {
    ?>

    <section class="section section__posts" <?php 
    tt_background_image($posts_background_image);
    ?>
>
        <div class="section__inner-wrapper">
            <span id="<?php 
    echo row_slug();
    ?>
"></span>

            <h2 class="section__title"><?php 
    echo row_item($postParent);
    ?>
</h2>

            <?php 
    if ($loop->have_posts()) {