Support » Fixing WordPress » custom post types – wp_list_categories() – edit title attribute

  • I have a few different custom post types and taxonomies in my site. I can list each specific set of taxonomies for each custom post type just fine, but the title attribute will remain “View all posts filed under…” I’d like to be able to change that based on each custom post type.

    This is where I’ve gotten so far…

    $taxonomy = 'port_cats';
    $orderby = 'name';
    $title = '';
    $show_count = 0;
    $hierarchical = 0;
    $hide_empty = 0;
    $use_desc_for_title = 0;
    $port_args = array (
      'taxonomy' => $taxonomy,
      'orderby' => $orderby,
      'title_li' => $title,
      'show_count' => $show_count,
      'hierarchical' => $hierarchical,
      'hide_empty' => $hide_empty,
      'use_desc_for_title' => $use_desc_for_title
    echo str_replace( 'View all posts filed under', 'View all projects filed under',wp_list_categories( $port_args ) );

    Hopefully those of you smarter than I can help me with my dilemma.

    Thanks in advance.

  • The topic ‘custom post types – wp_list_categories() – edit title attribute’ is closed to new replies.