Custom Layout not Rendering Correctly with Beaver Builder?
|
/ Documentation /Custom Code Snippets/Astra Theme & Pro Filters/ Custom Layout not Rendering Correctly with Beaver Builder?

Custom Layout not Rendering Correctly with Beaver Builder?

If you’re experiencing issues with custom layout rendering incorrectly in Beaver Builder when using the Astra theme?

Adding the below provided filter to your child theme’s functions.php file might indeed resolve the problem.

add_filter( 'astra_addon_bb_render_content_by_id', '__return_true' );

Here’s a breakdown of what this filter does and how it might help:

Sometimes, Beaver Builder might not render custom layouts correctly due to conflicts or specific handling by themes. This filter attempts to bypass any potential issues by instructing Beaver Builder to render content by its ID, which might resolve layout rendering issues.

This filter, astra_addon_bb_render_content_by_id, is specific to the Astra theme and Beaver Builder integration. It likely adjusts how content is rendered within Beaver Builder.

Filter Action: __return_true() is a WordPress function that simply returns true. By adding this filter, you’re essentially telling Beaver Builder to render content by its ID.

Make sure you understand the implications of adding code to your theme’s functions.php file, especially if you’re not using a child theme. Always backup your site before making such changes, and test thoroughly to ensure it resolves the issue without causing any unintended outcomes.

Refer this doc on How to Add Custom PHP Code?

Was this doc helpful?
What went wrong?

We don't respond to the article feedback, we use it to improve our support content.

Need help? Contact Support
On this page

Download is Just A Click Away!

Enter your email address and be the first to learn about updates and new features.

This field is required.

REWIND

YEAR IN REVIEW

Scroll to Top
Now choose your preferred
page builder addon
Choose your preferred page builder addon

Download is Just A Click Away!

Enter your email address and be the first to learn about updates and new features.

Download Free Astra Theme - Modal Popup Form