How to Create Unique Hero Sections on Different Pages in Colibri WP
Content
Many Colibri WP users encounter a common challenge when designing their websites: they want a unique hero section on each page, but any change they make seems to apply to all pages. This guide explains why this happens and provides the most effective solutions.
The Problem: Global vs. Page-Specific Hero Sections
Based on community reports, this behavior occurs because certain hero sections are designed as global templates. When you edit a global section, the changes propagate across every page that uses it. This is useful for maintaining consistent headers or footers but frustrating when you need page-specific content.
Users have reported issues such as:
- Adding a text element in one page's hero appears on all pages.
- Deleting the hero from one page removes it from everywhere.
- Inability to have a unique subtitle or secondary text below the page title.
Common Solutions and Workarounds
1. Use the Page Excerpt for a Unique Subtitle
A clever workaround discovered by the community involves using the page's excerpt field as a second text area. By default, the excerpt field might not be visible for pages.
Step-by-Step:
- Add the following line of code to your theme's
functions.phpfile to enable excerpts for pages:add_post_type_support( 'page', 'excerpt' ); - After saving the file, edit any page. You should now see an "Excerpt" meta box in the WordPress editor.
- Enter your unique subtitle or secondary text in this field.
- You may need to modify your hero section template to display this field. This often requires some knowledge of PHP or consulting the Colibri WP documentation for the correct function to call the excerpt.
Note: Always create a child theme before modifying the functions.php file to prevent your changes from being overwritten during theme updates.
2. Avoid Using the Global Hero Template
The core of the issue is often the use of a global, site-wide hero section. The solution is to create page-specific hero sections instead.
How to do it:
- When editing a page, try to add a new hero section from within the page's content area, not from a global header template.
- Use the Colibri WP builder to design a hero section directly on the page. This section should be unique to that page's content and not affect other pages.
- If your theme forces a global hero, you may need to disable it for individual pages and then build a custom one in its place. Look for theme options like "Page Settings" or "Content Layout" that might control this.
3. Understanding Reusable Sections (And Their Limits)
While Colibri WP offers reusable sections, community threads indicate they cannot be inserted into certain components like tabs. Furthermore, a reusable section is still a single entity; editing it will change it everywhere it is used. For truly unique page content, avoid using a reusable section as a hero if you need to change its text per page.
Conclusion
The desire for unique page heroes is a common design goal. The behavior of global sections copying across pages is not a bug but a design pattern for consistency. By using page-specific excerpts or building heroes directly into page content, you can achieve the unique look you want for each page on your site.
Related Support Threads Support
-
Second text element in hero contenthttps://wordpress.org/support/topic/second-text-element-in-hero-content/
-
Is it possible to Reuse a section or even copy, paste inside the Tab componenthttps://wordpress.org/support/topic/is-it-possible-to-reuse-a-section-or-even-copy-paste-inside-the-tab-component/
-
Cannot use different hero in different pageshttps://wordpress.org/support/topic/cannot-use-different-hero-in-different-pages/
-
Grouping together blockshttps://wordpress.org/support/topic/grouping-together-blocks/
-
Different eatures in different postshttps://wordpress.org/support/topic/different-eatures-in-different-posts/
-
How do I actually USE a reusable section I’ve saved?https://wordpress.org/support/topic/how-do-i-actually-use-a-reusable-section-ive-saved/
-
Copy elements accross pageshttps://wordpress.org/support/topic/copy-elements-accross-pages/