|
|
@@ -0,0 +1,38 @@
|
|
|
+<?php
|
|
|
+/*
|
|
|
+ * Template for the Studio → Projects child page (/studio/projects).
|
|
|
+ * Lists every post in the `studio` category (moved off page-studio.php).
|
|
|
+ */
|
|
|
+get_header(); ?>
|
|
|
+<div class="container leader">
|
|
|
+ <div class="row mt-5">
|
|
|
+ <h1><em><?php the_title(); ?></em></h1>
|
|
|
+ </div>
|
|
|
+ <div class="row">
|
|
|
+ <?php $i = 0; $query = new WP_Query( array( 'category_name' => 'studio', 'posts_per_page' => -1 ) ); while ( $query->have_posts() ) : $query->the_post(); ?>
|
|
|
+ <div class="col-lg-3">
|
|
|
+ <div class="studio-thumbnail">
|
|
|
+ <?php
|
|
|
+ if ( has_post_thumbnail() ) {
|
|
|
+ $img_url = wp_get_attachment_image_src( get_post_thumbnail_id(), 'studio' );
|
|
|
+ } else {
|
|
|
+ $img_url = get_post_meta( get_the_ID(), 'featured_image_url' );
|
|
|
+ }
|
|
|
+ ?>
|
|
|
+ <a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( '%s', 'daw' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><img class="studio-thumb" src="<?php echo esc_url( $img_url[0] ?? '' ); ?>" width="100%" alt="<?php the_title(); ?>"/></a>
|
|
|
+ </div>
|
|
|
+ <article class="studio">
|
|
|
+ <div class="entry-content">
|
|
|
+ <h5><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( '%s', 'daw' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h5>
|
|
|
+ <?php dw_good_excerpt( 110 ); ?>
|
|
|
+ </div>
|
|
|
+ </article>
|
|
|
+ </div>
|
|
|
+ <?php if ( ( ++$i % 4 ) == 0 ) : ?>
|
|
|
+ </div>
|
|
|
+ <div class="row">
|
|
|
+ <?php endif; ?>
|
|
|
+ <?php endwhile; wp_reset_postdata(); $i++; ?>
|
|
|
+ </div>
|
|
|
+</div>
|
|
|
+<?php get_footer( 'home' ); ?>
|