Get access to all 633 Bricks code tutorials with BricksLabs Pro
Related Tutorials..
Checking for Post Type in Bricks
A way to output elements conditionally based on the current post type in the loop in Bricks.
Categories:
Tags:
Pro
Getting Field Values from a Connected CPT when using Meta Box Relationship in Bricks
Conditionally render elements in a single template of a CPT depending on the value of a regular custom field.
Categories:
Tags:
Pro
Conditionally Outputting Query Loop Item Based on Post Meta in Bricks
Rendering query-loop enabled posts depending on the value of each post's custom field value is tricky because by default, the custom field plugins' functions or…
Categories:
Tags:
Conditional Rendering for Logged in/out Users by CSS Classes in Bricks
This tutorial shows how Bricks builder's bricks/element/render filter can be used to conditionally output elements having a class of logged-in to logged-in users only and…
Categories:
Tags:
Pro
Condition to Check if the Current Category Has At Least One Child
Looking to render an element in the category archive Bricks template only if the category of the current category archive page is a parent? This…
Categories:
Tags:
Conditionally Hide a Section on a Specific Taxonomy’s Term Archives in Bricks
A user asked: I have a CTA in the footer of my site, which I have custom fields on various templates, etc to populate. I…
Categories:
Tags:
Weekday Condition in Bricks
As of Bricks 1.7, the built-in "Weekday" condition does not work correctly. This is most likely due to it not taking the site's timezone (set…
Categories:
Tags:
Pro
Check If The Latest Post Was Published in The Last X Minutes
In this Pro tutorial we shall define a custom function that takes in the number of minutes as an argument and returns true if there…
Categories:
Tags:
Pro
Condition for checking Bricks content
Only outputting Bricks content when a Page is built with Bricks, otherwise display WP content.
Categories:
Tags: