laravel redirect using javascript code example Example: javascript redirect laravel route window.location.href = "{{ route('show-all-prescription')}}";