I have a view in site/index.php where I have this dropdownList, is dependent of another one but so far is working great.
<?=
$form->field(new \app\models\Tours(), 'nombre')->dropDownList(
[],
[
'prompt' => 'Programa',
'id' => 'child1_child2'
]
)->label(false);
?>
the problem with this is that I can't rescue the value of the option that is active in the dropdown.
When I change from one option to another there is no change in the html, In this image
for example I selected the option "tour 6" but it should be something letting me know that I changed the default option to "tour 6" right?
I understand that I can do this with JS. I tried using the #id
to interact with the option
value, but I think there is something missing in my dropdown code in order to rescue the value of the selected option.