selectStatic php notice

I have a line in .volt file :

{{ select_static('job-cat', job_cat, 'using': ['id', 'name'], 'useEmpty': true, 'emptyText': '', 'class': 'form-control') }}

it's compiled to (line 16):

<?php echo $this->tag->selectStatic(array('job-cat', $job_cat, 'using' => array('id', 'name'), 'useEmpty' => true, 'emptyText' => '', 'class' => 'form-control')); ?>

In php log file I see the following notice:

Notice: Array to string conversion in /Users/IGonza/git/xxx/app/cache/usersxxxxxappviewsjobadd.volt.php on line 16

I'm not sure where it's coming from... What's wrong with the code?



36.5k

It not support, you try select

{{ select('job-cat', job-cat, 'using': ['id', 'name'], 'useEmpty': true, 'emptyText': '', 'class': 'form-control') }}


6.8k

If it's not supported.. why does it work? I just get weird notice. Select element is in html result



6.8k
<?php echo $this->tag->select(array('job-cat', $job_cat, 'using' => array('id', 'name'), 'useEmpty' => true, 'emptyText' => '', 'class' => 'form-control')); ?>

Notice: Array to string conversion in /Users/IGonza/git/xxx/app/cache/usersigonzagitxxxappviewsjobadd.volt.php on line 16



6.8k

There is no notice if I use :

'using': 'name'

And it generates :

<select id="job-cat" name="job-cat" class="form-control" using="name">

Is this a bug of 2.0.0 version?