Automatically load custom product attribute with collection (every time)

You can do this with the following XML in your config.xml:

<frontend>
    <product> 
        <collection> 
            <attributes> 
                <ATTRIBUTECODE/>
            </attributes>
        </collection>
    </product>
</frontend>

But ATTENTION: This can become a performance issue, because it loads the attribute every time the product collection is loaded! If you added too many attributes, the performance can get worse!

 

Leave a Reply

Your email address will not be published. Required fields are marked *

 

This site uses Akismet to reduce spam. Learn how your comment data is processed.