I'm making a form with yii2, now I have two field:
<?php echo $form->field($model, 'Protocol')->textInput(['maxlength' => true])->dropDownList(
array("rtsp://"=>"rtsp","rsmt://"=>"rsmt","http://"=>"http"), // Flat array ('id'=>'label')
['prompt'=>'Select'] // options
); ?>
<?php echo $form->field($model, 'url')->textInput(['maxlength' => true]); ?>
How can I take the selection from Protocol's drop down list and automatically add it to the below URL field? Like this: I type the http://
in the field manually, is there anyway I can make it automatic?