We are moving our forum in GitHub Discussions. For questions about Phalcon v3/v4 you can visit here and for Phalcon v5 here.

Passing variable in partial (volt)

I need to pass $categ which is taken from controller. The following code work well. The problem is that I'm trying to be consistent in volt.

<?php $this->partial("blocks/categoryListBrowse", array('title' => 'Browse by Categories', 'parent_id' => "$categ", 'column' => '2')) ?>

The following code does not work:

{{ partial("blocks/categoryListBrowse", ['title': 'Categories1', 'parent_id': '$categ']) }}


It should be:

{{ partial("blocks/categoryListBrowse", ['title': 'Categories1', 'parent_id': categ]) }}

Without quotes and "$" symbol.