• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Adding a Footer container to Entry Meta in Archive Loops

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › Adding a Footer container to Entry Meta in Archive Loops

This topic is: not resolved

Tagged: Archive Loops, custom post types, Entry Footer

  • This topic has 2 replies, 2 voices, and was last updated 9 years, 9 months ago by marakas.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • November 16, 2013 at 6:10 pm #73485
    Lord_Devi
    Member

    Hi all,

    Ok so I have another issue here I do not know how to resolve... I created a Custom Post Type called "epilator-reviews" for my site.

    I got it all working fine, included in my archive loops properly and such. With one exception as far as I can tell. The entries are styled differently in my archive loop than the standard posts.

    A standard post in my archive loop has entry meta code that looks like this (Gotten using firebug):

    <footer class="entry-footer">
       <p class="entry-meta">
          <span class="entry-categories">
             Filed Under:
             <a rel="category tag" title="View all posts in Misc" href="http://vainsovain.com/misc/">Misc</a>
          </span>
          <span class="entry-tags">
             Tagged With:
             <a rel="tag" href="http://vainsovain.com/tag/review/">Reviews</a>
          </span>
       </p>
    </footer>

    In contract, my custom post type seems to be missing the <footer></footer> tags! :

    <p class="entry-meta">
       <span class="entry-categories">
    Filed Under:
          <a rel="category tag" title="View all posts in Epilators" href="http://vainsovain.com/review/epilator/">Epilators</a>
    ,
          <a rel="category tag" title="View all posts in Reviews" href="http://vainsovain.com/review/">Reviews</a>
       </span>
       <span class="entry-tags">
          Tagged With:
          <a rel="tag" href="http://vainsovain.com/tag/review/">Reviews</a>
       </span>
    </p>

    So my MAIN question is how do I go about adding the <footer> tags to my custom post type just as the standard post has?

    My secondary question.. Does anyone have any good material they could link me to that might help me understand how I can go about theming such things with more control? Looking around the web for such material has proven to be very daunting for me.

    I can find things like:
    http://wpgenesis.blogspot.ca/2013/04/custom-page-template-in-genesis-child.html?showComment=1384646304588#c7351187565693157643

    Or

    http://www.nathanrice.net/blog/genesis-loop-hooks/

    But all I want to do is say "This looks like this now, I need to make it look like that!" and so much of the documentation I find doesn't put their info into quality context for a newbie like me to be able to go from start to finish. 🙁

    http://vainsovain.com/blog/
    January 4, 2014 at 1:00 am #83072
    marakas
    Member

    Is there no resolution on this yet? Actually, I'm running into the same issue and very curious on how to resolve this. I also have a custom post type that shows everything except the .entry-footer container.

    Any pointers would be greatly appreciated. Thanks!

    January 4, 2014 at 2:32 am #83078
    marakas
    Member

    This is not too elegant, but it works. I still don't like it because it's too much of a hack. Hopefully someone can come up with a more elegant solution. I'm sure this is very easy to do.

    
    remove_action( 'genesis_entry_footer', 'genesis_post_meta' );
    add_action( 'genesis_entry_footer', 'sp_post_meta_filter' );
    function sp_post_meta_filter() {	
    	global $post;
    	echo '<footer class="entry-footer"><p class="entry-meta">'
    		. '<span class="entry-categories">' 
    		. 'Filed Under: <a href="http://vainsovain.com/review/epilator/" title="View all posts in Epilators" rel="category tag">'
    		. 'Epilators</a>, '
    		. '<a rel="category tag" title="View all posts in Reviews" href="http://vainsovain.com/review/">Reviews</a></span>';
    
    	if( $tags = wp_get_post_tags($post->ID) ) {
    
    		echo '<span class="entry-tags">Tagged With: ';
    		
    		$tags = wp_get_post_tags( $post->ID );
    		$num_tags = count($tags);
    		$c = 0;
    		
    		foreach( $tags as $tag ) {
    			echo '<a rel="tag" href="http://vainsovain.com/tag/' . $tag->slug . '/">' . $tag->name . '</a>';
    			$c++;
    
    			if ( $c !== $num_tags )
    				echo ', ';			
    		}
    		echo '</span>';
    	}
    	echo '</p></footer>';
    }
  • Author
    Posts
Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘Design Tips and Tricks’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2023 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble