Level 75
Do a new token.
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
This is my form
<form class="records_retrieval" action="/temprorary/show" method="post">
<table id="retrieval" class="table">
<thead>
<th></th>
<th>County</th>
<th>Crime Type</th>
<th>Date</th>
<th>Select</th>
</thead>
<tbody>
@foreach($reports as $key=>$report)
@if($report->crime_type!="ALL")
<tr>
<td>{!! $key+1 !!}</td>
<td>{!! $area_code[$report->area] !!}@if(is_admin())<a href="/report/delete/{{$report->id}}"> (x)</a>@endif</td>
<td>{!! $report->crime_type !!}</td>
<td>{!! $report->date !!}</td>
<td><input type="checkbox" name="id[]" value="{{$report->id}}"></td>
</tr>
@endif
@endforeach
</tbody>
</table>
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<input type="submit" name="show_records" value="Show Records" class="pull-right show_records_btn" >
<input type="submit" name="delete_records" value="Delete Records" class="pull-right delete_records_btn">
When i click on show records, page load normal, but after refresh it return TokenMismatchException in VerifyCsrfToken.php line 68:
In routes written
Route::post('/temprorary/show','RecordsController@temprorary');
Route::get('/record/temprorary',['as'=>'temprory_retrieval','uses'=>'RecordsController@retrieval']);
Please or to participate in this conversation.