• 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

customizing post meta – snippet not working

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 › customizing post meta – snippet not working

This topic is: resolved

Tagged: post meta snippets in functions, simple edits

  • This topic has 5 replies, 2 voices, and was last updated 10 years ago by micki.
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • March 18, 2013 at 11:49 am #29055
    micki
    Participant

    hi, i am trying to customize the text prior to the category, instead of the default "filed under". i inserted this into my functions file:

    /** Customize the post meta function */
    add_filter( 'genesis_post_meta', 'post_meta_filter' );
    function post_meta_filter($post_meta) {
    if ( !is_page() ) {
    $post_meta = '[post_categories before="Blog Category: "] [post_tags before="Tagged: "]';
    return $post_meta;
    }}

    which i got from the snippets page and it is not changing anything.

    I then tried this:

    /** Customize the post meta function */
    add_filter('genesis_post_meta', 'post_meta_filter');
    function post_meta_filter($post_meta) {
    if (!is_page()) {

    $post_meta = 'Blog Category: [post_categories], Tagged: [post_tags]';
    return $post_meta;
    }}

    no change.

    i am using MomPrenuer Child Theme.  Am i missing something? thanks

    March 19, 2013 at 12:56 am #29322
    Dorian Speed
    Member

    I can help you with this code, but it might be easier if you use the Genesis Simple Edits plugin - it makes this all a bit simpler.


    Bringing websites Up to Speed
    Firebug will light the way to understanding the secrets of the Internet!

    March 19, 2013 at 1:45 am #29331
    micki
    Participant

    thanks, i did install simple edits but it just makes me curious as to why these aren't working,  the first snippet is from StudioPress...

    March 19, 2013 at 1:57 pm #29482
    micki
    Participant

    i thought for anyone else who may have this issue, I read on the old forum that simple edits can conflict with snippets, such as the above, added to the functions file when trying to customize post meta.

    http://www.studiopress.com/support/showthread.php?t=122707&highlight=post+meta+description

    March 20, 2013 at 2:20 pm #29790
    Dorian Speed
    Member

    Did you get your layout working the way you wanted?


    Bringing websites Up to Speed
    Firebug will light the way to understanding the secrets of the Internet!

    March 20, 2013 at 9:36 pm #29854
    micki
    Participant

    yes, got rid of simple edits, works perfect, thanks

  • Author
    Posts
Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘customizing post meta – snippet not working’ is closed to new 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