• Hi,

    Wanted to see if anyone had any suggestions on how to create a custom page template to remove the top title area, called entry-header.

    I can accomplish this with CSS in my Child Theme

    .page-id-412 .entry-header, .featurette-divider
    {
    display: none;
    }

    But kind of sloppy to do this for 20 plus pages.

    I do have a custom-page-php set up, just copied the page template code and renamed it.

    But I am really lost on this code. No simple way to omit the title or so forth.

    Anyone out there need to do this? Maybe can share a template?

    Thanks, Tom

Viewing 6 replies - 1 through 6 (of 6 total)
  • Maybe I am missing the point here…certainly do not know what you have planned in the future…

    It appears that you have this customization applied to most of your pages, so, why not eliminate the page id’s which will allow the code to act on all pages, then after that code use page id’s to undo this customization on the pages you do not want it to affect, like this:

    .entry-header, .featurette-divider { display: none; }
    .page-id-399 .entry-header, .page-id-94 .entry-header, .page-id-83 .entry-header, .page-id-55 .entry-header, .blog .entry-header { display: inherit; }

    I don’t know if I found all the instances…

    Also…as your code currently sits, you have duplicated the featurette divider unnecessarily…as it is written, it is not affected by the page id…it affects all featurette dividers…

    Just a suggestion…

    Thread Starter MoochCat

    (@moochcat)

    Thanks,

    That is a great suggestion.

    I could not see a way to target that specific featurette divider and if I did not remove it then it inserts a blank space at the top that was not wanted. But as I don’t think it shows up much elsewhere in the theme it should be fine for now. I did it back into the second line of CSS for inclusion in those pages with an entry header, looks good.

    Thanks again for your help!

    Tom

    Thread Starter MoochCat

    (@moochcat)

    For some reason this CSS fix worked, and my earlier one as well, and then just stopped working.

    The CSS is being overridden by something and the .entry-header keeps populating.

    I tried going back to my original CSS, no go, and even tried adding it to the Customizr custom css box.

    Any thoughts?

    Tom

    Thread Starter MoochCat

    (@moochcat)

    For the time being I took them all out:

    h1.entry-title, h2.entry-title, h3.entrytitle {
    display: none;
    color: #4682b4;
    width: 100%;
    }

    .featurette-divider
    {
    display: none;
    }

    Seems to work for now.

    Tom

    I’m sorry…guess I misunderstood as well as I gave you incorrect advice…sorry again…

    Let’s see if I have this right…you want to eliminate the page title, page icon and featurette dividers on all pages?

    Edit: Do you want to keep the blog post titles, post icons and featurette dividers between posts?

    If yes to both of the above…You could try this:

    Add:
    .page .entry-header { display: none; }

    Remove the code I gave you in my first reply.
    Remove all instances similar to:
    .page-id-412 .entry-header, .featurette-divider { display: none; }
    Remove these:

    h1.entry-title, h2.entry-title, h3.entrytitle { display: none; color: #4682b4; width: 100%; }
    
    .featurette-divider { display: none; }
    
    /* Remove Post/Page Icon */
    .page #main-wrapper h1.format-icon:before { content: none; }

    Let me know if I missed anything…

    Including if I have misunderstood… ??

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Custom Page Template to remove title area (entry header)’ is closed to new replies.