Getting options stored in a custom attribute select.

Permalink
When working with custom attributes, what is the correct way to get the value stored in a 'select' attribute?

ob7dev
 
ob7dev replied on at Permalink Reply
ob7dev
Maybe I should have tried this before asking, but my answer will differ from any thing I've read on this.

I easily retrieved the attributes using the same method you would any other custom attribute, then I looped through them with a foreach command:

<? $attributes = $c->getAttribute('custom_select_attributes') ?>
<? foreach ($attributes as $attribute): ?>
<li><?=$attribute?></li>
<? endforeach; ?>


Hopefully thats helpful to someone else doing the same thing for the first time. If anyone has other ways of doing this, feel free to post on how you do it instead.