Skip to content

Commit

Permalink
Changes logout to POST
Browse files Browse the repository at this point in the history
Signed-off-by: snipe <snipe@snipe.net>
  • Loading branch information
snipe committed Nov 8, 2021
1 parent b5855e7 commit 38c36af
Showing 1 changed file with 13 additions and 6 deletions.
19 changes: 13 additions & 6 deletions resources/views/layouts/default.blade.php
Expand Up @@ -354,10 +354,17 @@
@endcan
<li class="divider"></li>
<li>
<a href="{{ url('/logout') }}">
<i class="fa fa-sign-out fa-fw" aria-hidden="true"></i>
{{ trans('general.logout') }}
</a>

<a href="{{ route('logout') }}" onclick="event.preventDefault(); document.getElementById('logout-form').submit();">
<i class="fa fa-sign-out fa-fw"></i> {{ trans('general.logout') }}
{{ csrf_field() }}
</a>

<form id="logout-form" action="{{ route('logout') }}" method="POST" style="display: none;">
{{ csrf_field() }}
</form>


</li>
</ul>
</li>
Expand Down Expand Up @@ -832,7 +839,7 @@

<!-- end main container -->

<div class="modal modal-danger fade" id="dataConfirmModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal modal-danger fade" id="dataConfirmModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
Expand All @@ -845,7 +852,7 @@
{{ csrf_field() }}
{{ method_field('DELETE') }}

<button type="button" class="btn btn-default pull-left" data-dismiss="modal">{{ trans('general.cancel') }}</button>
<button type="button" class="btn btn-default pull-left" data-dismiss="modal">{{ trans('general.cancel') }}</button>
<button type="submit" class="btn btn-outline" id="dataConfirmOK">{{ trans('general.yes') }}</button>
</form>
</div>
Expand Down

0 comments on commit 38c36af

Please sign in to comment.