diff --git a/resources/views/layouts/lang.blade.php b/resources/views/layouts/lang.blade.php index a4e6e7b..11ff14c 100644 --- a/resources/views/layouts/lang.blade.php +++ b/resources/views/layouts/lang.blade.php @@ -2,4 +2,16 @@ @else -@endif \ No newline at end of file +@endif + + +{{-- Redirects to https if enabled in the advanced-config --}} +@if(config('advanced-config.redirect_https') == 'true') +@php +if (! isset($_SERVER['HTTPS']) or $_SERVER['HTTPS'] == 'off' ) { + $redirect_url = "https://" . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; + header("Location: $redirect_url"); + exit(); +} +@endphp +@endif diff --git a/resources/views/layouts/sidebar.blade.php b/resources/views/layouts/sidebar.blade.php index 94b1c81..29f33fd 100755 --- a/resources/views/layouts/sidebar.blade.php +++ b/resources/views/layouts/sidebar.blade.php @@ -131,8 +131,8 @@ if($url1sb == '200' or $url2sb == '200') { @if(auth()->user()->role == 'admin')