From f9c4bd9b5af8c3285842515b5659ef03f21a66d2 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Tue, 3 Jul 2018 21:45:17 +0200 Subject: Ajax instead of form for avatar post. --- resources/views/layouts/app.blade.php | 2 ++ resources/views/profile.blade.php | 31 ++++++++----------------------- 2 files changed, 10 insertions(+), 23 deletions(-) (limited to 'resources/views') diff --git a/resources/views/layouts/app.blade.php b/resources/views/layouts/app.blade.php index 3204af3..f20d74a 100644 --- a/resources/views/layouts/app.blade.php +++ b/resources/views/layouts/app.blade.php @@ -82,6 +82,8 @@ @yield('content') + + {{ csrf_field() }} \ No newline at end of file diff --git a/resources/views/profile.blade.php b/resources/views/profile.blade.php index 3d1eee2..c4a7db0 100644 --- a/resources/views/profile.blade.php +++ b/resources/views/profile.blade.php @@ -1,31 +1,17 @@ @extends('layouts.app') @section('content')
-
- @if ($message = Session::get('success')) - -
+
+
- - {{ $message }} - +
- - @endif @if (count($errors) > 0) -
- Whoops! There were some problems with your input. -
-
-
    - @foreach ($errors->all() as $error) -
  • {{ $error }}
  • - @endforeach -
+
+ Whoops! There were some problems with your upload - please try again.
- @endif
-
+
@@ -35,11 +21,10 @@
-
+
-
- @csrf +
Please upload a valid image file. Size of image should not be more than 2MB. -- cgit v1.2.3