/** * Outputs the content for the current Text widget instance. * * @since 2.8.0 * @access public * * @param array $args Display arguments including 'before_title', 'after_title', * 'before_widget', and 'after_widget'. * @param array $instance Settings for the current Text widget instance. */ public function widget($args, $instance) { $posts = array(); $post_args = array('post_type' => 'collaborators', 'post_status' => 'publish', 'posts_per_page' => -1, 'orderby' => 'menu_order', 'order' => 'ASC'); $posts = get_posts($post_args); echo $args['before_widget']; ?> <div class="row"> <div class="fourteen columns centered l-padded-small"> <ul> <?php if ($posts) { foreach ($posts as $post) { setup_postdata($post); ?> <li> <?php if (!empty(get_field('link', $post->ID))) { ?> <a href="<?php __the_field('link', 'esc_url', $post->ID); ?> " target="_blank"> <?php } ?> <img src="<?php __the_field('logo', 'esc_url', $post->ID); ?> " /> <?php if (!empty(get_field('link', $post->ID))) { ?> </a> <?php } ?> </li> <?php } } wp_reset_postdata(); ?> </ul> </div> </div> <?php echo $args['after_widget']; }
/** * Outputs the content for the current Text widget instance. * * @since 2.8.0 * @access public * * @param array $args Display arguments including 'before_title', 'after_title', * 'before_widget', and 'after_widget'. * @param array $instance Settings for the current Text widget instance. */ public function widget($args, $instance) { $widget_title = !empty($instance['title']) ? $instance['title'] : ''; $widget_text = !empty($instance['text']) ? $instance['text'] : ''; /** * Filter the content of the Text widget. * * @since 2.3.0 * @since 4.4.0 Added the `$this` parameter. * * @param string $widget_text The widget content. * @param array $instance Array of settings for the current widget. * @param WP_Widget_Text $this Current Text widget instance. */ $text = apply_filters('widget_text', $widget_text, $instance, $this); echo $args['before_widget']; if (!empty($title)) { echo $args['before_title'] . $title . $args['after_title']; } ?> <div class="row l-ignore-overlay"> <div class="fourteen columns centered"> <h2 class="no-pad"><?php echo $widget_title; ?> </h2> <hr style="border-color: <?php __the_field('color_theme'); ?> ;" /> <?php echo !empty($instance['filter']) ? wpautop($text) : $text; ?> </div> </div> <?php echo $args['after_widget']; }
?> <hr style="border-color: <?php __the_field('color_theme', 'esc_attr', $page_id); ?> ;" /> <div class="row open-graph-data"> <div class="ten columns"> <h5><?php echo $og_title; ?> </h5> <p><?php echo $og_desc; ?> </p> <p><a href="<?php __the_field('external_url', 'esc_url'); ?> " target="_blank"><?php __the_field('external_url', 'esc_url'); ?> </a></p> </div> <div class="five columns push_one"> <img src="<?php echo $og_image; ?> " /> </div> </div>
<?php $element['dynamic_thumb'] = 'dynamic_normal'; ?> <li class="easy-instagram-item"> <a href="<?php echo esc_url($element['thumbnail_link_url']); ?> " target="_blank"> <img src="<?php echo esc_url_raw($element['thumbnail_normal_link_url']); ?> " /> <div class="instagram-feed-overlay"> <div class="overlay" style="background-color: <?php __the_field('color_theme'); ?> ;"></div> <h4 class="icon smaller no-pad"><i class="text-white icon-instagram"></i></h4> <h6 class="caption smaller text-white no-pad"><?php echo esc_html($element['thumbnail_caption']); ?> </h6> </div> </a> </li> <?php } ?>
/** * Outputs the content for the current Text widget instance. * * @since 2.8.0 * @access public * * @param array $args Display arguments including 'before_title', 'after_title', * 'before_widget', and 'after_widget'. * @param array $instance Settings for the current Text widget instance. */ public function widget($args, $instance) { $widget_title = !empty($instance['title']) ? $instance['title'] : ''; $widget_text = !empty($instance['text']) ? $instance['text'] : ''; $widget_bullets = !empty($instance['bullets']) ? $instance['bullets'] : ''; $bullets = explode(PHP_EOL, $widget_bullets); $color_field = get_field_object('color_theme'); $color = get_field('color_theme'); $color_label = strtolower($color_field['choices'][$color]); /** * Filter the content of the Text widget. * * @since 2.3.0 * @since 4.4.0 Added the `$this` parameter. * * @param string $widget_text The widget content. * @param array $instance Array of settings for the current widget. * @param WP_Widget_Text $this Current Text widget instance. */ $text = apply_filters('widget_text', $widget_text, $instance, $this); echo $args['before_widget']; ?> <div class="row light typography"> <div class="fourteen columns centered l-padded"> <h2 class="no-pad"><?php echo $widget_title; ?> </h2> <hr style="border-color: <?php __the_field('color_theme'); ?> ;" /> <div class="row"> <div class="twelve columns"> <?php echo !empty($instance['filter']) ? wpautop($text) : $text; ?> <div class="row"> <?php for ($i = 0; $i < 3; $i++) { ?> <div class="five columns"> <h6 class="regular bigger"> <?php for ($j = 0; $j < 3; $j++) { ?> <?php if (!empty($bullets[$i * 3 + $j])) { echo $bullets[$i * 3 + $j]; } ?> <br /> <?php } ?> </h6> </div> <?php } ?> </div> <div class="l-v-margin xxlarge button standard mobile-text-center <?php echo $color_label; ?> "> <a href="<?php echo home_url(); ?> /case-studies">View Samples</a> </div> </div> <div class="four columns text-center"> <img class="services-icon" src="<?php echo get_template_directory_uri(); ?> /assets/img/icon-<?php echo strtolower($widget_title); ?> .svg" /> </div> </div> </div> </div> <?php echo $args['after_widget']; }
<?php /** * Standard Post Format template */ $page_id = get_option('page_for_posts'); ?> <h1 class="no-pad"><?php the_title(); ?> </h1> <hr style="border-color: <?php __the_field('color_theme', 'esc_attr', $page_id); ?> ;" /> <?php the_content();
"></a> <?php the_field('full_logo_svg', 'options'); ?> </div> </div> <?php baldwin_output_business_info('footer-section internal'); ?> <div class="footer-section external"> <?php baldwin_output_business_logos(); baldwin_output_social_links(); ?> <p class="l-v-margin tiny text-center"><?php __the_field('copyright_notice', 'esc_html', 'options'); ?> </p> </div> </div> <?php } ?> </footer><!-- #colophon .site-footer --> </div><!-- #page --> <?php wp_footer(); ?>
/** * Outputs the content for the current Text widget instance. * * @since 2.8.0 * @access public * * @param array $args Display arguments including 'before_title', 'after_title', * 'before_widget', and 'after_widget'. * @param array $instance Settings for the current Text widget instance. */ public function widget($args, $instance) { add_action('wp_footer', array($this, 'baldwin_staff_widget_init'), 99); add_action('wp_footer', 'baldwin_output_team_bios'); $posts = array(); $post_args = array('post_type' => 'staff', 'post_status' => 'publish', 'posts_per_page' => -1, 'orderby' => 'menu_order', 'order' => 'ASC'); $posts = get_posts($post_args); echo $args['before_widget']; ?> <div class="row"> <div class="fourteen columns centered l-padded-small"> <ul class="team-list"> <?php if ($posts) { foreach ($posts as $post) { setup_postdata($post); $bio_id = strtolower(str_replace(' ', '', get_the_title($post->ID))); ?> <li> <a href="#" class="text-white team-bio-trigger" data-bio="#<?php echo $bio_id; ?> "> <div class="team-member toggle" gumby-classname="is-active" gumby-on="mouseover mouseout" style="background-image: url('<?php __the_field('picture', 'esc_url', $post->ID); ?> ');"> <div class="overlay" style="background: <?php __the_field('color_theme', 'esc_attr', $post->ID); ?> ;"></div> <div class="l-ignore-overlay team-member-copy text-center"> <h5 class="name bigger bold uppercase no-pad"><?php echo get_the_title($post->ID); ?> </h5> <p class="position regular uppercase no-margin text-center"><?php __the_field('position', 'esc_html', $post->ID); ?> </p> </div> </div> </a> </li> <?php } } wp_reset_postdata(); ?> </ul> </div> </div> <?php echo $args['after_widget']; }
<div class="row"> <div class="fourteen columns centered"> <div class="row"> <div class="eleven columns"> <h1 class="no-pad"><?php __the_field('tagline'); ?> </h1> </div> </div> <div class="l-v-margin l-bordered"> <h5 class="light no-pad"><span class="regular">Client:</span> <?php __the_field('client'); ?> <span class="l-spaced">/</span> <span class="regular">Services:</span> <?php __the_field('services'); ?> </h5> </div> </div> </div> </div> <?php if (have_posts()) { while (have_posts()) { the_post(); the_content(); } } ?>
/** * */ function baldwin_output_business_info($wrapper = '') { ?> <div class="<?php echo $wrapper; ?> "> <h5 class="regular">Dayton Office</h5> <p class="l-v-margin small"> <a href="<?php __the_field('dayton_office_map', 'esc_url', 'options'); ?> " target="_blank"><?php the_field('dayton_office_address', 'options'); ?> </a><br /> <a href="tel:+1<?php echo str_replace('.', '', get_field('dayton_office_phone', 'options')); ?> "><?php __the_field('dayton_office_phone', 'esc_html', 'options'); ?> </a><br /> <a href="mailto:<?php echo antispambot(get_field('dayton_office_email', 'options')); ?> "><?php echo antispambot(get_field('dayton_office_email', 'options')); ?> </a> </p> </div> <div class="<?php echo $wrapper; ?> "> <h5 class="regular">Louisville Office</h5> <p class="l-v-margin small"> <a href="<?php __the_field('louisville_office_map', 'esc_url', 'options'); ?> " target="_blank"><?php the_field('louisville_office_address', 'options'); ?> </a><br /> <a href="tel:+1<?php echo str_replace('.', '', get_field('louisville_office_phone', 'options')); ?> "><?php __the_field('louisville_office_phone', 'esc_html', 'options'); ?> </a><br /> <a href="mailto:<?php echo antispambot(get_field('louisville_office_email', 'options')); ?> "><?php echo antispambot(get_field('louisville_office_email', 'options')); ?> </a> </p> </div> <?php }
</div> <?php if (get_field('has_button', $post->ID)) { ?> <div class="row l-v-margin xlarge call-to-action"> <div class="ten columns push_two"> <div class="button solid mobile-text-center <?php echo $color_label; ?> "> <a href="<?php __the_field('button_link', 'esc_url', $post->ID); ?> "><?php __the_field('button_text', 'esc_html', $post->ID); ?> </a> </div> </div> </div> <?php } ?> </div> <?php $i++; } }