I have an attribute called 'made_to_order' and it has a dropdown select (in the backend of Magento) with two outcomes 'yes' or 'no'. At the moment I'm just echoing the yes or no on the frontend. However, ideally I'd like to show different html dependent on the attribute value. For example, if 'yes' then green color font, if 'no' then red color font.
Can anyone please help with the code for this? My current code is:
<p style="font-size: 1.1em;line-height:1.2em;"><?php echo $_product->getAttributeText('made_to_order') ?></p>
Thank you very much