Knowledgebase

How to create and manage attributes in PrestaShop 1.5-1.6

Attributes are used to create product combinations. So before you can add variations to products you have to create the attributes that you'll use for this purpose. Each attribute, also referred to as an attribute group, has some attribute values assigned to it. For example, if the attribute is size the values could be small, medium, large, etc.

Add Attribute Groups

To add attributes/attribute groups, go to Catalog menu>Product Attributes sub-menu. In PrestaShop 1.5 it's Catalog>Attributes and Values. On the page that opens click on the button Add new attribute. This will open the form for adding/editing attributes. The main options that you have to configure are Name and Public name. In the first one type the name of the attribute as you want it to appear in the back office, and in the second one type the name that you want to be shown on the frontend.

If the module Layered Navigation is enabled, on the form you'll also see the settings URL, Meta title, Indexable. In the field for URL you can put the part of the full URL that corresponds to the attribute. For example, if you put primary-color, the URL of an example product that uses this attribute will have the form yourdomain.com/14-product-name.html#/primary-color-green. If you leave the field blank, the name of the attribute is used. With the Meta title option you can specify some title for the attribute to be used by search engines.

The option Attribute type is set to Drop-down list by default. It determines how the attribute values belonging to the attribute can be selected on the frontend. You can change it to Radio button. If the attribute group has colors for its values then you can select Color from this option. This will display a color picker on the frontend.

After you're done with the options click on the Save button.

Add Attribute Values

Once you have an attribute/attribute group you can add values to it. To do this go to Catalog menu>Product Attributes sub-menu and click on the Add new value button. On the page that opens select the attribute group from the respective option and type the name of the value in the field for Value. The options URL and Meta title are available if the Layered Navigation module is enabled. In the field for URL you can type the part of the URL that corresponds to the attribute value (e.g. green in yourdomain.com/14-product-name.html#/color-green). In the Meta title field you can type a title to be used by search engines.

On the form there are two options that can be used if the value is a color. These are Color and Texture. You can use the Color option to select the exact color shade. You can type the hex value in the field, or you can click on the small color icon on its right side and select the shade from the window that pops out. If the color is not just one color but a mixture or a pattern of different colors you can use the Texture option to select an image that shows what it is.

After you're ready click on the Save button to save the value and go back, or on the button Save then add another value to save it and add more values.

Manage Existing Attributes and Attribute Values

You can edit and delete any of the existing attributes and attribute values. You can also change their positions; this reflects the order in which they are shown on the frontend. When you go to Catalog menu>Product Attributes sub-menu (Catalog>Attributes and Values in PrestaShop 1.5) a table displays the existing attributes. For each attribute there's an Edit button with which you can edit its settings. In PrestaShop 1.5 it's an icon that looks like a pencil.

Next to the edit button there's an arrow. When you click on it a drop-down menu will appear. It contains a button Delete with which you can delete the attribute and a button View which will display a table with the attribute values associated with the attribute. This table has the same buttons with which you can edit and delete the attribute values. In PrestaShop 1.5 there's no such drop-down menu next to the edit buttons for attributes. There's a separate icon that looks like trash can with which you can delete the attribute. Next to it there's a + symbol that will expand a panel with a table listing the attribute values assigned to the attribute.

For screenshots and some more details you can also read the tutorial on how to add and manage product attributes in PrestaShop.

Was this answer helpful?

 Print this Article

Also Read