some pages don't have "entry-header"

This topic contains 7 replies, has 4 voices, and was last updated by  Stiofan O’Connor 9 years, 9 months ago.

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
  • Author
    Posts
  • #11462

    j007w
    Free User
    Post count: 56

    Hi guys,

    I noticed that a couple pages, such as author and add listing, don’t have the “entry-title fn” class for the page title inside another div called “entry-header”. I’m using Avada and the title of these pages are not being recognized in the Page Title Bar.

    I found that those same pages don’t have the $class_header in their respective functions in geodirectory_template_actions.php so I added them (ex. shown below) but it’s not working. I know I shouldn’t modify this file; I’m just testing for now. Once I get it to work I’ll remove/add action to the child function file.

    From this:

    
    
    $class = apply_filters( 'geodir_page_title_class', 'entry-title fn' );
    echo '<h1 class="'.$class.'">'.get_the_title().'</h1>';

    To this:

    
    
    $class = apply_filters( 'geodir_page_title_class', 'entry-title fn' );
    $class_header = apply_filters( 'geodir_page_title_header_class', 'entry-header' );
    echo '<header class="'.$class_header.'"><h1 class="'.$class.'">'.get_the_title().'</h1></header>';

    Any tips on doing this the right way?

    Thanks so much!!!

    #11463

    j007w
    Free User
    Post count: 56

    Oops…I meant they don’t have “entry-header” from the $class_header variable. They do have “entry-title fn” from the $class variable.

    Thanks!

    #11464

    Guust
    Moderator
    Post count: 29970

    I forwarded this to the Avada child theme developer.

    #11481

    John Allsopp
    Expired Member
    Post count: 399

    You are right – these seem to be missing from the core file. I am guessing this is an oversight, and not missing by design, so i will notify Stiofan to get this fixed in core.

    #11484

    John Allsopp
    Expired Member
    Post count: 399

    …also the Avada plugin doesn’t add these page to the title bar. I will look at updating that situation too 🙂

    #11489

    j007w
    Free User
    Post count: 56

    Morning.

    Thanks, Guust and John! That sounds great.

    Hope you’ll have a great weekend.

    #11528

    j007w
    Free User
    Post count: 56

    Hi everyone,

    Want to share that I found a solution.

    First I need to add the code that I mentioned above. Then, in child theme’s function.php add the following per needed page inside the gd_avada_current_page_title_bar function.

    This one is for the author page:

    
    
    if( geodir_is_page('author') ) {
    	remove_action( 'geodir_search_page_title', 'geodir_action_author_page_title',10);
    	ob_start() ; // Start buffering;
    	geodir_action_author_page_title();
    	$title = ob_get_clean();
    	avada_page_title_bar( $title, $subtitle, $secondary_content );
    }

    Thanks!

    #11615

    Stiofan O’Connor
    Site Admin
    Post count: 22956

    I have added the “entry-header” to core.

    Thanks,

    Stiofan

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

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket