Jump to content

Get product attribute value


luke-p5

Recommended Posts

Hi I'm new in PrestaShop developing,

I created a module were i need to read the value of a product attribute called fee_custom
With id 5  and type drop-down list.

I'm using hookActionCartSave.


Are there some way to get the value of this attribute selected in the product?

 

I need get that value to add a new tax claculated based on this value.

Thanks for help.

Regards.

Link to comment
Share on other sites

Have you tried to use Product::getAttributesParams?

If this doesn't work try direct usage of class Attribute? Something like this (not tested)

$myAttribute = new Attribute($myID, $myLanguageId);
echo $myAttribute->name;

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...