How to Add a Custom Variable in Magento 2

First of all, navigate to System -> Custom Variables


How to Add a Custom Variable in Magento 2

In Variable Code enter the code of the variable without spaces and in lowercase letters. Somehting like working_hours.

Then enter the proper name of the Variable (it’s for internal use only, don’t worry).

Variable HTML Value: enter custom HTML code for your variable. (can skip it if don’t want any particular formatting for your plain text).
Variable Plain Value: Here you can enter the text for the variable. Here you can write, for example, that your working hours are from 12 am to 12 pm. Then, you can use this value on multiple pages of your store. And in variables you can change the value and won’t have to make changes on all pages of your store.


How to Add a Custom Variable in Magento 2

















Viewed 48 Times

Post On 2019-11-19