How do I create a numerical range for a link on to a custom taxonomy?
-
I am working on creating a music book for my band. I have created one custom taxonomy for both tempo and time signature. One part is a number. I would like to have that number shown on the post and then when you click on the link it shows all posts within that range i.e. 104-130. I also am putting time signatures in there so I would also want it to match the time signature (4/4 or 6/8 for example) so just probably an if then kind of thing maybe?
Thanks ahead of time for your help!
Here is what I have right now from my taxonomy (borrowed most of it from the new Twenty_seventeen which is the theme I’m building off of):
<?php
/* translators: used between list items, there is a space after the comma */
$separate_meta = __( ‘, ‘, ‘twentyseventeen’ );// Get Categories for posts.
$categories_list = get_the_category_list( $separate_meta );// Get Tags for posts.
$tags_list = get_the_tag_list( ”, $separate_meta );echo ‘<div class=”entry-footer”>’;
echo ‘<span class=”cat-tags-links”>’;echo ‘<span class=”tags-links”>’ . twentyseventeen_get_svg( array( ‘icon’ => ‘hashtag’ ) ) . ‘<span class=”screen-reader-text”>’ . __( ‘Tags’, ‘twentyseventeen’ ) . ‘</span>’ . $tags_list . ‘</span>’;
echo ‘<span class=”cat-links”>’ . twentyseventeen_get_svg( array( ‘icon’ => ‘folder-open’ ) ) . ‘<span class=”screen-reader-text”>’ . __( ‘Categories’, ‘twentyseventeen’ ) . ‘</span>’ . $categories_list . ‘</span>’;echo ‘</span>’;
echo ‘</div> <!– .entry-footer –>’;
?>
The page I need help with: [log in to see the link]
- The topic ‘How do I create a numerical range for a link on to a custom taxonomy?’ is closed to new replies.