skip to Main Content

Disabling The Page Header Title

In Total you can quickly and easily disable the page title either on a per-page/per-post basis or using a custom filter in a child theme to disable it using conditional statements for more advanced usage.

Disable Globally

If you want to remove the page header from ALL pages, posts and archives on the site you can do so via the Customizer at Appearance > Customize > General Options > Page Title and set the style to “hidden”.


Disabling on a Per Page/Post Basis

You can also disable the page header title on a per post or page basis using the Theme Settings metabox as shown in the screenshot below:

Disabling Via Filter

Now if you are a developer and want more control over the page title you can use the theme filter called “wpex_display_page_header” to show and hide the page title accordingly. See some great example functions below:

All custom functions should be added to a child theme’s functions.php or via the code snippets plugin so you don’t lose your edits in the future when you update your theme.

Disable Page Title For Products

Here is an example function using a conditional to hide the title for all singular posts under the “product” post type. You can of course tweak this function to fit your needs. It doesn’t just have to be products, you can use any WordPress conditional.

[gist id=”dcf9c969dbebf2c0b227″]

Disable Page Title On All Pages and Posts (everywhere)

The following snippet can be added to your child theme’s functions.php file to disable the main page header (title) on your entire site. In most cases this isn’t ideal, but some customers have requested it so here is how you do it!

[gist id=”4ed8b5b1e9750426d350″]
Back To Top