I have two custom product attributes that I'm using in my product page template files. One of them doesn't seem to work and I'm wondering if it's something to do with the attribute code.
The attribute codes are:
- small_promo
- c2c_height_1
This works:
<?php if ($block->getProduct()->getSmallPromo()): ?>
<!-- do something -->
<?php endif; ?>
This doesn't work:
<?php if ($block->getProduct()->getC2cHeight1()): ?>
<!-- do something -->
<?php endif; ?>
Is this bit wrong: getC2cHeight1 ? Is there another method I could try?