Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #1244285

    How do I set the tag page title to show above the description? Tag descriptions appear above the title on tag pages. Please assist.
    Example link provided.

    • This topic was modified 4 years, 2 months ago by dlrms. Reason: Edited topic title
    #1244678

    Hello….anybody here to help? Support, where art thou?

    #1245096

    Hi,

    Sorry for the delay. That is actually the title or name of the post type. We have to modify the tag.php template in order to move the tag description somewhere else in the archive page. Look for this block of code around line 24:

    
    <div class="category-term-description">
        <?php echo term_description(); ?></div>
    

    Best regards,
    Ismael

    #1245207

    Yes, had tried moving that snippet earlier before coming here for support. It breaks the styling of the archive page at top – tried in three different locations. Please be specific as to what I actually need to do. That is, where EXACTLY do I put/modify that block of code…..?

    #1245617

    Hi,
    Sorry for the late reply, instead of modifying the template, try adding this code to the end of your functions.php file in Appearance > Editor:

    function tag_page_title_above_tag_description(){
      ?>
      <script>
    (function($) {
      $(document).ready(function(){
         $('#top.tag .tag-page-post-type-title').detach().insertBefore('.category-term-description');
      });
     })(jQuery);
     </script>
    <?php
    }
    add_action('wp_footer', 'tag_page_title_above_tag_description');

    This should work for all tag pages.

    Best regards,
    Mike

    #1245619

    Thanks @Mike! Worked! Now that’s what ‘m talking about. Very helpful. Cheers!

    #1245627

    Hi,

    I’m glad this was resolved. If you need additional help, please let us know here in the forums.

    Best regards,
    Jordan Shannon

Viewing 7 posts - 1 through 7 (of 7 total)
  • The topic ‘Fix for Tag page title showing below tag description?’ is closed to new replies.