Remove social, utility links and breadcrumbs

  1. Newbie needs help :)

    I read and tried, however the problem remains the same. Read these:
    Social, utility > http://devpress.com/forums/topics/omitmodify-the-share-this-on-linksicons-on-blog-posts/
    Breadcrumbs > http://devpress.com/forums/topics/take-breadcrumbs-off-homepage/

    Thanks a lot :)

  2. elza. show us your functions.php file before we can help. it worked for two other people. should work for you too.

  3. I want to disable title too.

    functions.php:

    <?php
    
    /* Adds the child theme setup function to the 'after_setup_theme' hook. */
    add_action( 'after_setup_theme', 'news_child_theme_setup', 11 );
    
    function news_child_theme_setup() {
    
    /* Get the theme prefix ("hybrid-news"). */
    $prefix = hybrid_get_prefix();
    
    /* Removes breadcrumbs */
    add_filter( 'breadcrumb_trail_args', 'news_breadcrumb_trail' );
    
    /* Removes sidebar widget from home/page/singular etc */
    add_filter( 'sidebars_widgets', 'disable_all_widgets' );
    
    /* Remove published date from singular post */
    // add_filter( "{$prefix}_singular_byline", 'news_byline' );
    
    /* Removes utility links on posts */
    add_filter( 'news_entry_utility', 'disable_entry_utility' );
    
    /* Removes Sharing links */
    add_filter( 'news_entry_meta', 'disable_entry_meta' );
    }
    function news_breadcrumb_trail( $args = '' ) {
    $args['echo'] = false;
    return $args;
    }
    
    function disable_all_widgets( $sidebars_widgets ) {
    if ( is_page() ) // is_home, is_page, is_singular
    $sidebars_widgets[sidebar-secondary] = array( false ); // removing only footer "$sidebars_widgets['footer']"
    return $sidebars_widgets;
    }
    
    function disable_entry_utility() {
    return '<div class="entry-utility"></div>';
    }
    
    function disable_entry_meta() {
    return '<div class="entry-meta"></div>';
    }
    
    ?>
    
  4. I’ve edited the code you’ve pasted for the functions.php file to a version that I think would work. Come back to this thread. Copy and paste the code. You were basically missing add “news_” on some lines. And if the {prefix} code for the byline doesn’t work, replace that with news_ as well.

    I’m sorry the forum edit links aren’t working properly. I’m trying to track where the problem is coming from.

  5. Ah, there. I fixed replies editing for forums.

  6. I pasted the code above, but I still see all of them > http://qh.elza.ee/specials/

  7. Your parent theme directory is actually “hybrid-news” so try hooking into entry_utility via “hybrid-news_entry_utility” instead of news_entry_utility.

You must be logged in to reply to this topic.