• fgoellner

    (@friederun-goellner)


    Hi, I am using a child theme of fifteen and configured the plugin Tribe Events Calendar. It uses fifteen standard template for all kinds of display. I didn’t like that the nice title bar doesn’t display title with events. So I added this code to page.php
    <?php
    if (get_post_type() == ‘page’ && (the_title() == ”)){ ?><h1 class=”container single-entry-title”>Events</h1><?php }
    else {?>
    <h1 class=”container single-entry-title”><?php the_title(); ?></h1>
    <?php }
    It does work fine with posts (displaying the_title()) and Tribes Events Calendar displaying “Events”.
    It also works with all pages using “page-full-width.php” template. But it fails with pages using “standard” template. This template behaves with pages as “!= ‘page'” putting “events” in the title bar but displays page title somewhere unformatted out of any context.
    Why does standard template altered with this code above doesn’t display pages properly?
    Tried a lot to figure it out but without success.
    Help would be much appreciated, thank you very much.

  • The topic ‘standard template and title bar’ is closed to new replies.