Skip to content

Commit

Permalink
bugfix: reselect select form elements when validation fails
Browse files Browse the repository at this point in the history
  • Loading branch information
lsamshuijzen committed Jan 13, 2025
1 parent 7f8c822 commit 5a34690
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion resources/views/forms/components/dropDownSelect.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class="select form-field-text focus:select-secondary
<option disabled selected>{{ $placeholder }}</option>
{{-- from https://laravel.com/docs/11.x/blade#additional-attributes --}}
@foreach ($ElementsArray as $subject)
<option value="{{ $subject }}" @selected(old('{{ $sectionName }}') == $subject)>
<option value="{{ $subject }}" @selected(old($sectionName) == $subject)>
{{ $subject }}
</option>
@endforeach
Expand Down

0 comments on commit 5a34690

Please sign in to comment.