Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #12960

    i am trying to modify the avia_title function:

    if(is_post_type_archive()) $title = post_type_archive_title();

    this displays the pt archive title but not as $output .= ‘<h1 class=”main-title”>’.$title.'</h1>';

    any help?

    #77288

    found it:

    if(is_post_type_archive())

    {

    $post_type_obj = get_queried_object();

    $title = apply_filters(‘post_type_archive_title’, $post_type_obj->labels->name );

    }

    #77289

    Glad you found it! Thanks for posting the solution!

    Regards,

    Mya

Viewing 3 posts - 1 through 3 (of 3 total)

The topic ‘function avia_title for custom post type archive’ is closed to new replies.