method to use id when input type is an array

Posted 1 year ago by Thameera

$('#name').on('change',function(){ var price = $(this).children('option:selected').data('price'); $('#unit').val(price); }); this is my js function for get text field according to the change in dropdown but here i want input as multiple so i use array how can i define id here for js function {!!Form::text('unit', null, array('class' => 'form-control', 'placeholder' => 'Enter unit','id'=>'unit'))!!} this is my input form

Please sign in or create an account to participate in this conversation.