How to configure display conditions for global templates

  • Global templates use inclusion and exclusion conditions to control where headers, footers, and common blocks are displayed.
  • In WordPress and page builders, rules can be based on content type, taxonomies, hierarchy, author, or special pages such as the archive or 404.
  • Platforms like HubSpot allow you to create global modules/groups and edit them only once to update all templates that use them.
  • Advanced tools add configuration parameters, automation, and thresholds that fine-tune the behavior of template-based campaigns and sessions.

computer

If you work with visual page builders or advanced content management systems, knowing how to configure the display conditions of global templates is key to controlling which header, footer, blocks, or modules appear on each page. When managed properly, these conditions allow you to fully customize your site without losing overall consistency.

We'll break down, step by step, everything you need to know to master the rules for displaying templates and global content , both in page builders like Elementor and in global template systems from platforms like HubSpot or other tools that use campaign templates and flows. You'll see practical examples and all the configuration nuances so you don't miss a thing.

What are display conditions in global templates?

Display conditions are rules that specify where a global template will and will not be shown . Think of the header, footer, or a recurring block: you can decide whether it applies to the entire site, only to certain pages, only to blog posts, to a specific category, or even exclude it from a particular page.

In page builders like Elementor (from version 2.0 onwards), global templates are introduced for elements such as Header, Footer, Archive, 404 Page, etc. These templates use display conditions to control their scope: "Entire site," "Posts only," "Category X only," "Exclude homepage," etc., and combine Include/Exclude rules for very fine-grained control.

It's important to understand that each condition can be inclusive or exclusive . For example, you can include a header site-wide but add a rule to exclude it from the homepage. Additionally, you can have multiple versions of the same template (for example, several different headers) and assign them to different areas or content types.

Also note that these conditions can only be used in theme builder templates , not on individual pages created normally. Therefore, any advanced customization strategy involves creating templates and experimenting with the conditions.

General outline: Including and excluding in global templates

The basic logic is simple: INCLUDE conditions cause the template to be displayed in the defined locations, while EXCLUDE conditions prevent it from being displayed in those areas. From there, an options tree is organized according to content type, taxonomy, or context.

In the case of WordPress and page builders like Elementor, the conditions tree is structured into large blocks such as General, Archives, Single, Posts, Pages, Media, Author, 404 Page , etc. Within each of these, the criteria are further refined: all posts, only a specific post, categories, subcategories, tags, author, date, etc.

A key concept in WordPress is Archives . An archive is a list of posts that share a common element: all posts, all posts in a category, archives by date, by author, by tag, or by custom content types. Each archive type can be used as a display condition for a global template.

Display conditions: detailed options

General conditions

The "General" option usually includes the broadest condition: The entire site . This causes the template to load on any page, post, file, or content type. It's the typical starting point for a header or main footer.

However, this "Site-wide" rule can be overridden by more specific rules. When you define conditions in the "Single" block (for example, "Single > Posts > All"), those specific assignments take precedence over the Site-wide rule . Thus, a specific header for all posts will replace the generic header across the blog.

Archives: author, date, search, and entries

Within Files, you can control templates that are applied to content listings. Common options include:

All archives : The template will affect all archive listings (author, date, categories, tags, etc.). This is useful for defining, for example, a specific header only for archive pages.

Author file : Here there are two common variants: “All” (any file from any author) or select a specific author so that the template is only applied when viewing that author's file.

Archive date : This allows you to apply the template to archives like https://yourdomain.com/2022/07/, that is, lists of posts by date. This is useful if you want to display a specific design for chronological lists.

Search results : This applies to the results page when a user uses the site's internal search engine. A global template associated with this condition will only be displayed on the search page.

Post Archive : The "Post Archive" option controls the main blog listing (the page that displays all posts according to the Settings > Reading configuration). You can apply a specific header, title design, or information block only to that archive.

Categories and subcategories

Category-based criteria allow for very precise segmentation. They typically include:

Categories > All : The template applies to all category files (for example, any URL like https://yourdomain.com/category/news/).

Select a specific category : You choose an existing category so that the template is displayed only in that category's archive.

Direct child category of : the key here is the hierarchy. You can apply the template to subcategory files that are direct children of a parent category , but not to their "grandchildren." You can also filter by a specific category to further refine your search.

Any child category of : In this case, the rule encompasses all child subcategories and also sub-subcategories (grandchildren, great-grandchildren, etc.). The condition can be applied globally or linked to a specific parent category, displaying the template at all its descendant levels.

Tags

The tags section is similar to categories, but without hierarchy. You have two main options:

Everything : the template is displayed in the file of any tag , that is, in any URL like https://yourdomain.com/tag/offer/.

Specific tag : You choose an existing tag so that the template is applied only to that tag's file. This is useful if, for example, you want to highlight offers, sales, or recurring themes with a special design.

Unique: pages, posts, and other individual content

The "Unique" area refers to individual content types: pages, blog posts, and Custom Post Types (CPTs) . Here, you determine which global templates are used for each specific content type.

All unique : the template applies to any individual content (pages, posts, and CPTs). It's a good starting point when you want a consistent design, but remember that it can be overridden with more specific rules.

Homepage : This refers to the page you've set as your homepage in Settings > Reading. You can assign a completely different header or footer just for the homepage.

Specific conditions for tickets

In the "Entry" section, you can fine-tune things even further. You'll typically find:

Entries > All : The template will be applied to all blog entries, unless there is an even more specific rule.

Individual entry : You can select a specific entry so that the template is displayed only there. Ideal for sales pages, product launches, or highly featured content that requires a unique design.

In Category > All : the template will be displayed on all entries that have at least one associated category (virtually all entries, unless you have uncategorized content).

In a specific category : you choose a category and the template will only be applied to posts assigned to that category. This is perfect for, for example, creating a different header for "News" articles.

In a child of Categories : this option focuses on posts that belong to subcategories (direct or indirect children) of a given category. It allows you to discriminate by hierarchical levels , showing a different design only in certain branches of the blog.

In Tag > All : the template will be displayed on all entries that have any tag.

In Specific Tag : you choose a specific tag and limit the template to entries tagged with that term.

Entries by author > All : applies to all entries, regardless of the author.

Entries by specific author : you can configure a template that is displayed only in the entries of a specific author, very useful if you work with several writers and want to differentiate visual styles.

Terms and conditions for pages, landing pages and media

In the “Page” section you will have similar options but applied exclusively to pages (not posts):

Pages > All : The template is displayed on all pages of the site.

Specific page : You select a specific page to use a different header, footer, or global block than the rest.

Pages by author : both the "All" option (all pages by any author) and the "specific author" option allow you to play with different designs depending on who creates the page.

Landing pages : If your system distinguishes between regular pages and landing pages, you can apply templates only to landing pages. You can also choose a specific landing page for even finer customization.

Regarding “Media”, templates can also be applied to elements in the media library:

Media > All : Displayed on all attachments or pages associated with media (images, documents, etc.).

Specific medium : You select a specific media file to apply a unique template, which is unusual but possible in highly customized projects.

Media by author : You can display a different header or block depending on the author of the media documents.

Hierarchy: direct children, any child, and content by author

Conditions related to page hierarchy and custom content types are especially useful on large sites with complex structures.

Direct child of > All : the template is applied to all pages or CPTs that are direct children of another page or CPT.

Direct child of > Specific selection : You choose a page or content type as the "parent" and the template is used only on its direct children.

Any child of > All : extends the scope to children, grandchildren, and any lower hierarchical level. You will display the same template on all descendants of any page or CPT that has a hierarchy.

Any child of > Specific selection : similar to the above, but limited to the offspring of a specific page or CPT.

On the other hand, the general option By author allows you to display a template in any of the documents (pages, entries, media, CPT, etc.) of a specific author, or of all authors if you choose the "All" condition.

page 404

404-error-page

Finally, there's the 404 Page condition , which only affects the error page displayed when a user tries to access a non-existent URL. A specific global template is typically configured here to provide a friendly message, helpful links, and calls to action to retain the user.

Practical examples of display conditions

To better understand how all these rules work, it's helpful to look at some typical use cases that occur on real sites when working with global templates.

Header or footer for the entire site

The most basic configuration is to assign a global Header or Footer to the entire site . This will cause the template to be displayed everywhere in the project, except where a more specific condition has been defined to override it.

If you've also created another header with the condition "Single > Posts > All", this new header will take precedence over the one assigned to the entire site in all blog posts. The rest of the pages and sections will continue to use the general template.

Header or footer for the entire site except the homepage

Another classic scenario is wanting a general design for the entire site, but a completely different homepage. To do this, you create one header with the condition " Include > Entire Site" and another different header with the condition " Include > Homepage ". Because this is a more specific rule, the homepage header will only be displayed on that URL, while the rest of the site will use the generic one.

It is important that the special header for the home page is properly configured and that critical elements such as the logo or main menu are not missing, as it will be the first visual reference for your visitors.

Header or footer only for blog posts

If you want your blog to have its own visual identity, you can configure a header or footer template using the "Unique" > Posts > All condition . This way, each blog post will load that custom header, for example, with a breadcrumb, a "Blog" label, or a more editorial design.

For this to work seamlessly, it's recommended that a header or footer already be assigned to the entire site . This way, sections not included in the "Posts" category will continue to display a general header, and only the blog area will use the specific one.

Different template for a specific page

In projects with key pages (such as a services landing page, a sales page, or a course page), you can have a header or footer template that applies only to that page . In the condition, you choose "Single > Pages > Select specific page" and assign, for example, "Page 1".

In this way, that page will have a different design (for example, without a menu, with a larger top banner or with a reduced footer), while the rest of the sections will continue to use the generic template that you have configured in the Entire Site.

Specific template for entries of a specific category

If you want all posts with the category “News” to display a different header or global block, simply create a template and assign it to the condition Unique > Posts > In category > Select category “News”.

The result is that all posts in that category will have a customized appearance: for example, a breaking news label, a larger highlighted date, or a global module with links to more related news. All other posts, without that category, will retain the default template.

Global content on platforms like HubSpot

hubspot

Source: Digital Marketing Agency

In systems like HubSpot, in addition to display conditions, there's the concept of reusable global content (modules or global groups). These are sections you can use across multiple page templates, blogs, or emails. When you edit this global content, the changes are applied everywhere it's used.

Global content is created and managed from the Design Manager . There you can create a new module already marked as global, or convert existing modules or groups into global modules/groups for reuse across multiple templates.

Create global modules from scratch

To create a global module in a HubSpot-like environment, the flow is usually:

Access the Design Manager from the Content menu . In the search bar, use the menu “File > New File”. In the dialog box, select “Module” and click “Next”.

Next, you need to specify which types of content the global module will be used for (pages, blog, emails, etc.). For emails, there's an important limitation: global email modules cannot include CSS or JavaScript.

In the module's content scope section, select the "Global Module" option , assign a file name, and click "Create." This opens the module editor where you can define fields, structure, and style.

Convert local modules or groups into global ones

If you already have a template set up and want to reuse a block, you can convert it to a global block. To do this, in the Design Manager, open an existing template, select the module or group of modules, and from the inspector use the "Convert to Global Module/Group" option.

If you're creating a global group from multiple modules, you can first select them using the Control/Command key, group them (usually with a group icon), and then make that group global. This will give you a reusable block that you can drag to other templates.

Add a global module or group to drag-and-drop templates

In drag-and-drop templates, adding global content is very simple. Open the template in the Design Manager, go to the side inspector, click "+ Add" , search for the global module or group (by name, category, or tag), and drag it into the design.

Once in place, you just need to adjust the rest of the template elements and, when everything is ready, publish the template so that the changes are applied to the pages that use it.

Use of global content in coded templates

In coded templates, there is no visual "Convert to global group" option, so global modules must be created and referenced manually. The usual procedure is:

Create a new module in the Design Manager, mark it as “Global Module” in the content scope, define the fields needed to replicate the behavior of the original module, and save.

Next, copy the HubL snippet (the code snippet from the global module) and paste it into your coded template where you want it to appear. When you publish the module and template, that global content will be integrated into your design.

In more advanced development environments, developers can duplicate a module and set "global: true" in the meta.json file using the CLI, to make it global from the code and then update templates to use it.

Global content editing: where and how to do it

One of the advantages of global content is that it's edited once and updated on all sites where it's embedded. On platforms like HubSpot, you can do this from both the content editor and the design manager.

Edit global content from the content editor

If you're on a page or post, you can locate the global module using a specific icon (it usually marks global content in the content tree). Clicking the global content icon opens a dialog box where you can choose "Open in global content editor".

Within this global editor, you can use drag-and-drop tools to change text, images, and other internal modules of the global group. For example, in a global header, you can edit the logo module , adding a logo from your computer or the file manager, and define its alt text and the URL it points to.

Similarly, you can edit the navigation menu of the corresponding module by clicking on "Edit menu" and customizing links, hierarchy, and names from the settings dialog.

Previewing is also important: from the "View in" menu you can choose a page or post where that global content is being used to see how it looks in context, or select "Group only" to see it in isolation.

In multilingual projects, you can add or edit language variations of the global content, so that the same global header has versions for each language. Once everything is reviewed, click "Publish to [#] resources" to apply the changes to all pages and posts that use that template.

Edit global content from the Design Manager

More technically inclined developers or administrators often prefer to edit global modules directly in the Design Manager. They open the template containing the global group, click on it, and then select "Edit Global Group" from the "More" menu.

If the goal is to modify the global content only for a specific page, a local copy of that global group can be made, so that it is no longer shared and becomes an editable block only in that template or content.

After making the necessary adjustments (whether changes to fields, structure or styles), the "Publish changes" options are used to extend them to all content that uses a template with that global content.

Advanced configuration of templates and campaigns with parameters

woman working on computer

Beyond visual layout tools, there are advertising and automation platforms that allow you to configure campaign templates with configuration parameters that act as conditions or variations depending on the account, brand, or advertising platform.

For example, you can have a campaign template where the name, budget, dates, locations, or URL suffixes are dynamically adjusted depending on the client or platform (Google Ads or Microsoft Ads, for example). All of this is defined using parameters and logical expressions.

Campaign name with feed parameters

In the campaign settings, the "Campaign Name" field can be constructed by combining feed columns and fixed text, using a syntax such as f:"brand", f:"origin_country" of:"destination_country". This way, the campaign name is automatically generated based on the source data.

Additionally, you can create custom configuration parameters to adapt that name for different clients. For example, for a brand called Albatross Flights, you could define a campaign name with "Thanksgiving breaks" between the brand and country fields; while for Golden Eagle Flights, you could use "New Year breaks" in the same pattern.

Dynamic and static budgets

You can also set custom budgets . For some accounts, you can use dynamic formulas that calculate the budget based on a field in the feed, for example: if(f:"price_usd" > 1000, 100, 50). This means that if the price exceeds a certain threshold, the budget is higher; otherwise, it's lower.

For other accounts, you can opt for static budgets, such as always setting 50 monetary units. This way, the same campaign template can be used for multiple clients with different budget requirements.

Dates, locations, and tracking URL

The start and end dates of campaigns can also be adjusted with parameters specific to each client or brand. For example, for Albatross Flights you could schedule campaigns from May to October, while for Golden Eagle Flights the campaigns could run from May to December.

Regarding locations, you can define different audiences depending on the client account: the United States and Canada for some campaigns, and various European countries (United Kingdom, Ireland, France, etc.) for others, all managed from configuration rules.

Campaign URL options allow you to use a common base URL format and then vary the tracking parameters. For example, you can use {lpurl} as a placeholder for the destination URL, but add different suffixes depending on the platform: one for Google Ads (with campaign, keyword, and device tracking, and a src=google parameter) and another for Microsoft Ads (without the device parameter and with src=msft). This makes it easy to track and analyze across multiple channels using a single template structure.

Advanced options in flow templates and assessment sessions

In performance management and assessment calibration tools, templates also have multiple configuration options that act as behavior and display conditions during workflows.

For example, you can enable automatic form submissions at the end of a session, force submission from a validation step, allow sorting columns in container views, or activate priority sorters within sessions. All of this is controlled from the base template settings.

Automation of shipments and validations

A common option is to automatically submit forms upon completion and logout , which is especially recommended for final calibrations of performance forms. Alternatively, a "Force Submission" button can be enabled in the validation step so administrators can push forms to the correct stage even if issues arise.

If container views are enabled, you can display a ranking column to sort evaluated participants within each container. Additionally, this column can be marked as required, preventing the session from closing if not all participants have been ranked.

Analysis, commenting, and preview tools

There are advanced features such as the calibration-related priority classifier , which allows you to compare up to ten subjects side-by-side with an "Analyze" button. You can also enable the commenting option, so that those with writing permissions can add, edit, or delete comments per evaluator, visible in the session, reports, and profile views.

To make the process more intuitive, you can preview a profile by hovering over an employee's name in a list. Clicking directly on the name takes you to the employee's full profile.

Another important setting is the inclusion of inactive users. By default, they are usually excluded, but you can enable an option to include them in the session if your process requires it.

Compliance criteria, multiple selection, and partial anonymization

Some templates allow you to activate compliance criteria for rating guidelines , so the session cannot be closed until those rules are met. You can also enable multiple selection with drag and drop, which is very useful for adjusting ratings for several evaluators at once.

For reasons of bias and diversity, there are options to hide photos of those being evaluated (photon-free calibration) in list, bin, and matrix views, as part of unbiased business initiatives. At the same time, gender indicators can be enabled, allowing you to see gender ratios by list, location, or matrix, even showing gender segregation within each cell.

Another advanced option is to accumulate comments from other sessions based on the same template , so you can see all of an employee's historical comments centralized in one comments dialog tab.

Automatic activation of sessions and performance thresholds

tidy desk

In the automation section, you can configure template-based sessions to be automatically activated on a specific date via work requests. A general activation date is defined (which can be overridden by the date of each individual session), and an option is enabled to force activation, removing from the session anyone who does not meet the minimum validation requirements.

Performance thresholds are also defined . For example, after a certain number of evaluations (20 by default), the automatic and forced form submission processes run in the background, allowing the administrator to continue working while the system routes forms.

Another threshold controls the maximum number of unfiltered subjects visible (200 by default, with a maximum of 3000). Once this limit is exceeded, only filtered evaluators are displayed to improve performance. Finally, a maximum interval for rating changes can be set (for manual ratings only). If you attempt to raise or lower a rating by more points than allowed, an error message will be displayed, and the rating will revert to its original value upon session restart.

This whole set of options demonstrates that, in page builders as well as in campaign platforms or evaluation systems, the display and behavior conditions associated with global templates are key to controlling what happens, where and how, allowing you to maintain consistency while adapting each part of the system to the specific needs of your site, your campaigns or your internal processes.


Add as preferred source in Google