SHARE
TWEET

Untitled

a guest Jan 20th, 2019 68 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2.     /*Template Name: Team*/
  3. ?>
  4.  <?php get_header(); ?>
  5. <div class="works-page">
  6. <?php if ( have_posts() ) :
  7.     while ( have_posts() )
  8.         : the_post(); ?>
  9.  
  10.         <?php if ( $featured_image = get_the_post_thumbnail_url() ): ?>
  11.             <div class="featured-image" <?php echo 'style="background-image: url('.$featured_image.');"'; ?>></div>
  12.         <?php endif; ?>
  13.  
  14.         <section class="page-content-section">
  15.             <div class="row column">
  16.                 <h1 class="page-title"><?php the_title(); ?></h1>
  17.                 <div class="page-content"><?php get_content(); ?></div>
  18.             </div>
  19.         </section>
  20.  
  21.         <section class="team-section">
  22.             <div class="row">
  23.  
  24.                
  25.                 <?php $args = array (
  26.                     'post_type' => 'team',
  27.                     'posts_per_page' => -1,
  28.                     'order' => 'ASC'
  29.                     'order_by' => 'menu_order'
  30.                     );
  31.  
  32.                 $team_query = new WP_Query( $args ); ?>
  33.  
  34.                 <?php if($team_query -> have_posts () ) : ?>
  35.                     <?php while($team_query -> have_posts() ) : $team_query -> the_post(); ?>
  36.  
  37.                     <div class="columns medium-6 large-3">
  38.                         <div class="person">
  39.                             <?php if ( $featured_image = get_the_post_thumbnail_url() ): ?>
  40.                                 <div class="person-photo cover" <?php echo 'style="background-image: url('.$featured_image.');"'; ?>></div>
  41.                             <?php endif; ?>
  42.                             <h2 class="person-name"></h2>
  43.                             <div class="person-content"></div>
  44.                         </div>
  45.                     </div>
  46.  
  47.                 <?php endwhile; ?>
  48.             <?php endif; ?>
  49.             <?php wp_reset_postdata(); ?>
  50.  
  51.             </div>
  52.         </section>
  53.  
  54.     <?php endwhile; ?>
  55. <?php endif; ?>
  56. </div>
  57. <?php get_footer(); ?>
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top