Be sure to checkout our newest add-on, Speedy — Advanced Caching for ExpressionEngine.

Compatibility updates:

  • Publisher is EE5 compatible, but it does not currently support the Fluid field (it's in the works).

Ticket: Parent Block Variables don’t work in conditionals

Status Resolved
Add-on / Version Bloqs 4.0.21
Severity
EE Version 5.2.4

Jarod Clark

Jul 10, 2019

Hello, it’s entirely possible that this is intended behavior, but it wasn’t clear one way or another in the docs here: https://eebloqs.com/documentation/nesting

The issue we’re seeing is with using the “Block Variables” as described toward the bottom of that page.

We have an atom defined on the parent block called block_var_theme. This is a simple radio option that outputs a string. We can output the variable fine in the child block with {block_var_theme} on our template, however, doing a conditional doesn’t work.

Example: {if block_var_theme == 'white'}.

It would be great if this worked for conditionals, but if that’s possible, then probably some updates need to be made to the documentation.

Thanks!

#1

BoldMinded (Brian)

Jul 10, 2019

Did you try

{if '{block_var_theme}' == 'white'}.
#2

Jarod Clark

Jul 10, 2019

AH! That version works.

Thanks.

Would recommend a note about that in the docs then 😊

#3

BoldMinded (Brian)

Jul 10, 2019

Good to hear! Glad I could help.

Login to reply

Contact

For add-on support, please use the Support section. General inquries and pre-sale questions can be sent to support@boldminded.com.