Skip to content
This repository was archived by the owner on Jan 2, 2025. It is now read-only.

Commit 73e3b35

Browse files
author
Michael Sisk
committed
Update storyline list output.
Ensure that only the bottom-most story lines in a nested tree have their comics displayed.
1 parent 5f991c8 commit 73e3b35

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

-/php/tags.php

+4-1
Original file line numberDiff line numberDiff line change
@@ -6682,13 +6682,16 @@ public function start_el( &$output, $term, $depth = 0, $args = array(), $current
66826682
array(
66836683
'taxonomy' => $term->taxonomy,
66846684
'field' => 'id',
6685+
'include_children' => false,
66856686
'terms' => $term->term_id
66866687
)
66876688
)
66886689
) );
66896690

6691+
$output .= '<li class="webcomic-term ' . $term->taxonomy . ' webcomic-term-' . $term->term_id . ( $selected === $term->term_id ? ' current' : '' ) . '"><a href="' . ( 'archive' === $target ? get_term_link( $term, $term->taxonomy ) : WebcomicTag::get_relative_webcomic_link( $target, $term->term_id, false, $term->taxonomy, preg_replace( '/_(storyline|character)$/', '', $term->taxonomy ) ) ) . '" class="webcomic-term-link"><div class="webcomic-term-name">' . $term_title . ( $show_count ? " ({$term->count})" : '' ) . '</div>' . ( ( $show_image and $term->webcomic_image ) ? '<div class="webcomic-term-image">' . apply_filters( 'webcomic_term_image', wp_get_attachment_image( $term->webcomic_image, $show_image ), $show_image, $term ) . '</div>' : '' ) . '</a>' . ( ( $show_description and $term->description ) ? '<div class="webcomic-term-description">' . apply_filters( 'webcomic_term_description', $term->description, $term ) . '</div>' : '' ) . $feed_link;
6692+
66906693
if ( $the_posts->have_posts() ) {
6691-
$output .= '<li class="webcomic-term ' . $term->taxonomy . ' webcomic-term-' . $term->term_id . ( $selected === $term->term_id ? ' current' : '' ) . '"><a href="' . ( 'archive' === $target ? get_term_link( $term, $term->taxonomy ) : WebcomicTag::get_relative_webcomic_link( $target, $term->term_id, false, $term->taxonomy, preg_replace( '/_(storyline|character)$/', '', $term->taxonomy ) ) ) . '" class="webcomic-term-link"><div class="webcomic-term-name">' . $term_title . ( $show_count ? " ({$term->count})" : '' ) . '</div>' . ( ( $show_image and $term->webcomic_image ) ? '<div class="webcomic-term-image">' . apply_filters( 'webcomic_term_image', wp_get_attachment_image( $term->webcomic_image, $show_image ), $show_image, $term ) . '</div>' : '' ) . '</a>' . ( ( $show_description and $term->description ) ? '<div class="webcomic-term-description">' . apply_filters( 'webcomic_term_description', $term->description, $term ) . '</div>' : '' ) . $feed_link . '<' . ( $ordered ? 'ol' : 'ul' ) . ' class="webcomics">';
6694+
$output .= '<' . ( $ordered ? 'ol' : 'ul' ) . ' class="webcomics">';
66926695

66936696
$i = 0;
66946697

0 commit comments

Comments
 (0)