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?
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?
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 );
}
Glad you found it! Thanks for posting the solution!
Regards,
Mya
This topic has been closed to new replies.