Sindbad~EG File Manager
@for($i = 1; $i <= 10; $i++)
@php
$dato='int_opcion'.$i;
@endphp
@if($int->$dato)
<div class="form-check">
<input class="form-check-input" type="checkbox" name="respuesta{{ $int->id }}[]" value="{{ $int->$dato }}" id="checkbox{{ $int->id }}{{ $int->$dato }}">
<label class="form-check-label" for="{{ $int->id }}{{ $i }}">
{{ $int->$dato }}
</label>
</div><br>
@endif
@endfor
@if ($editar == 1)
@foreach ($respuestaint as $element)
@if ($int->id == $element->interrogante_id)
@php
$arreglo = unserialize($element->respuesta);
@endphp
@foreach ($arreglo as $arr)
<script>
document.getElementById("checkbox{{ $int->id }}{{ $arr }}").checked = true;
</script>
@endforeach
@endif
@endforeach
@endif
Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists