From 7c5183a882421394637588ddf4a5ce2810e1551a Mon Sep 17 00:00:00 2001 From: Chris Abraham Date: Thu, 17 Oct 2024 11:21:25 -0400 Subject: [PATCH] Use this more precise way of getting blog posts related to a project Signed-off-by: Chris Abraham --- .../themes/cncf-twenty-two/components/project-single.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/web/wp-content/themes/cncf-twenty-two/components/project-single.php b/web/wp-content/themes/cncf-twenty-two/components/project-single.php index 6f0b5411..8292ab07 100644 --- a/web/wp-content/themes/cncf-twenty-two/components/project-single.php +++ b/web/wp-content/themes/cncf-twenty-two/components/project-single.php @@ -303,7 +303,13 @@ class="wp-block-spacer is-style-20-40"> 'order' => 'DESC', 'orderby' => 'date', 'no_found_rows' => true, - 's' => $project_slug, + 'tax_query' => array( + array( + 'taxonomy' => 'lf-project', + 'field' => 'slug', + 'terms' => $project_slug, + ), + ), ); $related_query = new WP_Query( $related_args );