@foreach ($iq_group1 as $k => $v)
@php $opt_array = explode(",", $v['options']); @endphp
@if ($v['qtype'] == 1)
@foreach($opt_array as $x => $y)
@php $show_req = ''; @endphp
@if ( $x == 0)
@php $show_req = 'required';@endphp
@endif
@endforeach
@endif
Please choose your answer
@endforeach
@foreach ($iq_group2 as $k => $v)
@php $opt_array = explode(",", $v['options']); @endphp
@if ($v['qtype'] == 1)
@foreach($opt_array as $x => $y)
@php $show_req = ''; @endphp
@if ( $x == 0)
@php $show_req = 'required';@endphp
@endif
@endforeach
@endif
Please choose your answer
@endforeach