From b0ae50409d22a9b553d8ac3984f05b1f1e554b88 Mon Sep 17 00:00:00 2001 From: Antoine M Date: Thu, 11 Jul 2024 10:50:41 +0200 Subject: [PATCH] working on parcours singles data loop --- single-parcours-child.php | 75 ++++++++++++++++++++++++++++++++++++-- single-parcours-parent.php | 2 +- 2 files changed, 72 insertions(+), 5 deletions(-) diff --git a/single-parcours-child.php b/single-parcours-child.php index 4643e12..4cd5985 100644 --- a/single-parcours-child.php +++ b/single-parcours-child.php @@ -1,8 +1,75 @@ post_parent) ?? null; +$parentUrl = get_the_permalink($post->post_parent) ?? null; +$pageIcon = get_field('step_icon', $post->ID); ?> -
"> - -
\ No newline at end of file +
+ + + $parentTitle, + "title" => get_the_title(), + "page_icon" => $pageIcon, + "published" => get_the_date() + )); + ?> +
"> + +
+ + +
+ ID) ?? null; + $next_page_icon = get_field('step_icon', $next_post->ID) ?? null; + + + ?> + + + + + + + + + + + + + + + +
+ +
\ No newline at end of file diff --git a/single-parcours-parent.php b/single-parcours-parent.php index f07f4f2..37ab724 100644 --- a/single-parcours-parent.php +++ b/single-parcours-parent.php @@ -42,7 +42,7 @@ $chapterBlockIndex = build_page_chapter_index($blocks); // see utilities.php ID); -get_template_part("template-components/heading-box--parcours", null, array( +get_template_part("template-components/heading-box--parcours-parent", null, array( "pageIcon" => $pageIcon, "subtitle" => __("Parcours rénovateur", "homegrade-theme__texte-fonctionnel"), "title" => get_the_title(),