A
A
akula222016-03-25 23:45:26
JavaScript
akula22, 2016-03-25 23:45:26

How to take an array from a select and decompose it into inputs?

There is data (it is necessary to make an array)
Name, width, height
Name, width, height
Name, width, height

I need to display select ,

<?= $form->field($model, 'format')->dropDownList($array...

in which the name is selected, and the width and height from this name is inserted into two inputs, which will be below,
tell me how to do this?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Mylistryx, 2016-03-25
@Mylistryx

Well, the width and height can be passed in data- attributes, but the onChange handler will have to be written apparently.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question