I'm using the laravel framework. I populated my dropdown list with data from my database.
<select class="form-control" id="username" name="username" onchange="somerandonfunction(blah)">
<option value="" selected>Select User</option>
@foreach($getUsers as $list)
<option value="" ></option>
@endforeach
</select>
I want to be able to pass the value of the option clicked to a function in the onchange attribute in the select> tag. Is there a way to do this?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire