diff --git a/template-news.php b/template-news.php new file mode 100644 index 0000000..56d8cce --- /dev/null +++ b/template-news.php @@ -0,0 +1,67 @@ + '_wp_page_template', + 'meta_value' => "template-news.php" +); +$relatedPageTemplatePage = get_pages($args) ? get_pages($args)[0] : null; +$pageIcon = get_field('page_icon', get_queried_object_id()) ?? null; + +?> +
+ +
+
+ +

+

+
+ +
+ +
+ + "post", + "status" => "publish" +); +$posts = new WP_Query($args); + +?> +
+ + + posts as $key => $post) { + + $post_thumbnail = get_the_post_thumbnail($post->ID, 'full', array('class' => 'card-news__thumbnail card-post__thumbnail')) ?? null; + $post_tags = get_the_tags($post->ID) ?? null; + get_template_part( + 'template-components/cards/card-news', + null, + array( + 'card_variant' => 'activite', + 'post_ID' => $post->ID, + 'post_title' => $post->post_title, + 'post_thumbnail' => $post_thumbnail, + 'post_tags' => $post_tags, + ) + ); + } + + ?> +
+