$all_staff->the_post(); if (get_field("runner_staff") == true) { $meet_staff[] = array("name" => get_the_title(), "avatar" => sb_profile_avatar(get_the_ID()), "biography" => sb_profile_biography(get_the_ID()), "email" => get_field("runner_email"), "links" => get_field("runner_links")); } } } if (have_posts()) { while (have_posts()) { the_post(); ?> <main class="main page-about" id="content" role="main"> <div class="page-about__media"> <?php if (has_post_thumbnail()) { echo sb_responsive_image_helper(get_post_thumbnail_id(), "page-about__image"); } ?> </div> <div class="page-about__body"> <section class="content page-about__section page-about__section--intro"> <?php the_content(); ?> </section> <section class="page-about__section page-about__section--stats"> <ul class="stats stats--large"> <li class="stats__item"> <strong class="stats__value" data-counter><?php echo $meet_count; ?>
<?php $meet_location = sb_meet_location(get_field("meet_location")); $meet_theme = !empty($meet_location["locality"]) ? strtolower($meet_location["locality"]) : "severn"; $meet_coords = $meet_location["latitude"] . "," . $meet_location["longitude"]; if (has_post_thumbnail()) { $meet_image = sb_responsive_image_helper(get_post_thumbnail_id(), "meet-card__image"); } else { $meet_image = '<img class="meet-card__map" alt="Map showing the location of ' . $meet_location["name"] . '." srcset="https://maps.googleapis.com/maps/api/staticmap?size=320x320&scale=2&maptype=roadmap&markers=color:0xe84545%7C' . $meet_coords . '&zoom=15&key=' . GOOGLE_MAPS_API_KEY . '">'; } ?> <article class="meet-card grid__item" data-theme="<?php echo $meet_theme; ?> "> <a class="meet-card__link" href="<?php the_permalink(); ?> "> <div class="meet-card__media"> <?php echo $meet_image; ?> </div> <div class="meet-card__body"> <h1 class="meet-card__title"><?php the_title(); ?> </h1> <ul class="meet-card__meta"> <?php
</p> </div> </div> </a> </li> <?php } else { ?> <li class="search-results__item"> <a class="search-results__link" href="<?php the_permalink(); ?> "> <?php if (has_post_thumbnail()) { echo sb_responsive_image_helper(get_post_thumbnail_id(), "search-results__image"); } ?> <div class="search-results__body"> <div class="search-results__type"> Page </div> <h2 class="search-results__title"> <?php echo sb_search_highlight(get_search_query(), get_the_title()); ?> </h2> <div class="content search-results__content"> <p><?php echo sb_search_highlight(get_search_query(), get_the_excerpt()); ?>
<div class="wrapper" id="top"> <?php if (is_front_page()) { if (has_post_thumbnail()) { $intro_image = sb_responsive_image_helper(get_post_thumbnail_id(), "intro-panel__image"); } ?> <section class="intro-panel"> <?php echo $intro_image; ?> <div class="intro-panel__inner"> <div class="intro-panel__body"> <h1 class="intro-panel__title"> <?php the_title(); ?> </h1> <div class="content intro-panel__content"> <?php the_content(); ?> </div> </div> </div> </section> <?php } ?>