How to get product characteristics and attributes in the product frontend template
Forum rules
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
How to get product characteristics and attributes in the product frontend template
Laravel framework version: 9.37.0
Aimeos Laravel version: * 2022.07.2
PHP Version: 8.1.11
Environment: Linux
Hello, I want to get the product characteristics and attributes in this template for example
templates\client\html\common\partials\products.php
How do I go about doing this?
Aimeos Laravel version: * 2022.07.2
PHP Version: 8.1.11
Environment: Linux
Hello, I want to get the product characteristics and attributes in this template for example
templates\client\html\common\partials\products.php
How do I go about doing this?
Re: How to get product characteristics and attributes in the product frontend template
Add "attribute" and "product/property" to this configuration setting:
https://aimeos.org/docs/2022.x/config/c ... s/#domains
Then, you can access attributes and properties using:
https://aimeos.org/docs/2022.x/config/c ... s/#domains
Then, you can access attributes and properties using:
Code: Select all
$product->getRefItems( 'attribute', 'color', 'variant' ); // color variant attribute items
$product->getRefItems( 'attribute', '<type code>' ); // some attribute items by type
$product->getPropertyItems( '<property type>' ); // some property items by type
$product->getPropertyItems(); // all property items
$product->getProperties( '<property type>' ); // List of property values
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star
Re: How to get product characteristics and attributes in the product frontend template
Thank you, that works, I can access the attributes this way.