Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /*Template Name: Team*/
- ?>
- <?php get_header(); ?>
- <div class="works-page">
- <?php if ( have_posts() ) :
- while ( have_posts() )
- : the_post(); ?>
- <?php if ( $featured_image = get_the_post_thumbnail_url() ): ?>
- <div class="featured-image" <?php echo 'style="background-image: url('.$featured_image.');"'; ?>></div>
- <?php endif; ?>
- <section class="page-content-section">
- <div class="row column">
- <h1 class="page-title"><?php the_title(); ?></h1>
- <div class="page-content"><?php get_content(); ?></div>
- </div>
- </section>
- <section class="team-section">
- <div class="row">
- <?php $args = array (
- 'post_type' => 'team',
- 'posts_per_page' => -1,
- 'order' => 'ASC'
- 'order_by' => 'menu_order'
- );
- $team_query = new WP_Query( $args ); ?>
- <?php if($team_query -> have_posts () ) : ?>
- <?php while($team_query -> have_posts() ) : $team_query -> the_post(); ?>
- <div class="columns medium-6 large-3">
- <div class="person">
- <?php if ( $featured_image = get_the_post_thumbnail_url() ): ?>
- <div class="person-photo cover" <?php echo 'style="background-image: url('.$featured_image.');"'; ?>></div>
- <?php endif; ?>
- <h2 class="person-name"></h2>
- <div class="person-content"></div>
- </div>
- </div>
- <?php endwhile; ?>
- <?php endif; ?>
- <?php wp_reset_postdata(); ?>
- </div>
- </section>
- <?php endwhile; ?>
- <?php endif; ?>
- </div>
- <?php get_footer(); ?>
Add Comment
Please, Sign In to add comment