stenik/module-custom-var-accessor 1.0.3

Provides the ability to access custom var from every phtml template.

Type

magento2-module

License

MIT

Requires
Requires (dev)

None

Suggests

None

Provides

None

Conflicts

None

Replaces

None

Stenik\CustomVarAccessor module provides the ability to access custom var from every phtml template.

To fetch custom variable in template use:

<? $block->getVar($varCode, 'customVarName'); ?>

to fetch custom variable's name or

<? $block->getVar($varCode, 'customVarText'); ?>

to fetch custom variable's plain value or

<? $block->getVar($varCode, 'customVarHtml'); ?>

to fetch custom variable's html value
where $vatCode is the custom var's code