Cutline Theme Support Forums » Tips & Tricks

Adding Tags under posts in Cutline

(4 posts)
  • Started 4 years ago by remotesensingtools
  • Latest reply from scool2play

  1. Here's what I've done recently to add Tags under my posts in Cutline. I've changed the former 'Tags' word to 'Categories', and added the true 'Tags' below 'Categories'.

    I've also taken the liberty to make-sure this change to the template would be a cross-compatible method with older versions of WordPress (prior to version 2.3). If you're still preparing to upgrade to 2.3, then you can add this in and your Cutline will be ready and compatible.

    Copy/paste the code below, minus the backticks.

    `<?php if (function_exists('the_tags')) : ?>
    <p class="tagged"><span class="add_comment"><?php comments_popup_link('→ No Comments', '→ 1 Comment', '→ % Comments'); ?></span>Categories: <?php the_category(' · ') ?>
    Tags: <?php the_tags(''); ?></p>
    <?php else : ?>
    <p class="tagged"><span class="add_comment"><?php comments_popup_link('→ No Comments', '→ 1 Comment', '→ % Comments'); ?></span>Categories: <?php the_category(' · ') ?>
    <?php endif; ?>
    `

    The template files that you'll wish to edit are:

    1) Main Index Template (index.php)
    2) Archives (The first Archives template listed! NOT the one generated by Cutline! To distinguish the two, the WordPress archive-listing page is 'archive.php'. Cutline's Archives page is 'archives.php'.)
    3) Single Post (single.php)

    Find the location where the original code lives -- copy/paste the new code in. Simple.

    Enjoy!

    Note: I used the native display of WordPress tags to use a comma separator instead of Cutline's category middots. I ultimately felt that tags being separated in this way was a more accurate visualization for taxonomy. (I did retain the middot seperators for Categories, however. This distinction between the two is what looks more appropriate to me, and also helps to differentiate the two aesthetically.)

    Posted 4 years ago #
  2. Add another template page to that list, as I figured-out last night.:

    Search.php

    The search results, you might with to keep consistent, as it was already themed that way with the original 'categories' label.

    Posted 4 years ago #
  3. gymr4t
    Member

    Thanks for that addition. tesla generator wasn't letting me add the tags

    Posted 1 year ago #
  4. scool2play
    Member

    Thanks for the tip.

    Used Fire Trucks for Sale

    Posted 1 year ago #

RSS feed for this topic

Reply

You must log in to post.