I have set a new custom attribute called actiekorting with a value of 25% on a product. It shows perfectly in detailed product page. But when I'm trying to copy the same line on a different page (overview page of products) I get the following fatal error: Call to a member function productAttribute() on a non-object in etc..
Fix ‘Call to a Member Function productAttribute() on a Non-Object’ Error
fatal error
Best Answer
This is happening because the class this method belongs to hasn't been instantiated.
Make sure the object you're trying to call
productAttribute()
on is an instance ofMage_Catalog_Helper_Output
Example