Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #256869

    Hi,

    In the postS in “Title Bar Settings” you can choose display the Title Bar with Page Title and Breadcrumb Navigation.
    BUT the Page Title in all posts is the the word “BLOG”, not the name of the post!

    How can I correct this problem?

    THANKS

    #257026

    Hey CloudChoice!

    Thank you for using the theme.

    Please use this on functions.php to replace the title with the post title:

    add_filter('avf_title_args', 'fix_blog_page_title', 10, 2);
    function fix_blog_page_title($args,$id) {
    $args['title'] = get_the_title($id);
    $args['link'] = get_permalink($id);
    return $args;
    }

    Regards,
    Ismael

    #257333

    Hi,

    Thanks, works nicelly.

    Other question in this same topic. How can i chage the breadcrumbs in the posts?

    The original is :

    you stay here: Home / Blog / category / post name

    I would like to use something like that:

    you stay here: Home / Blog / post name

    Just, How remove the category in the breadcrumbs?

    #258136

    Hi!

    Insert this code into the child theme functions.php file:

    
    add_filter('avia_breadcrumbs_trail', 'avia_change_breadcrumb', 10, 1);
    function avia_change_breadcrumb($trail) {
    if(is_single() && get_post_type() == "post")
    {
    			$front 			= avia_get_option('frontpage');
    			$blog 			= avia_get_option('blogpage');
    			
    				if($blog != $front)
    				{
    					$blog = '<a href="' . get_permalink( $blog ) . '" title="' . esc_attr( get_the_title( $blog ) ) . '">' . get_the_title( $blog ) . '</a>';
    				}
    
    			$home 		= $trail[0];
    			$last 		= array_pop($trail);
    			unset($trail);
    
    			$trail[0] = $home;
    			$trail[] = $blog;
    			$trail[] = $last;
    
    }
    return $trail;
    }
    

    Best regards,
    Peter

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.