バージョン書いてなかったので、laravel5.8.3でやってみましたが
routers/web.php
php
1<?php
2
3/*
4|--------------------------------------------------------------------------
5| Web Routes
6|--------------------------------------------------------------------------
7|
8| Here is where you can register web routes for your application. These
9| routes are loaded by the RouteServiceProvider within a group which
10| contains the "web" middleware group. Now create something great!
11|
12*/
13
14Route::get('/', function () {
15 return view('welcome');
16});
17
18
19// add
20Route::get('/hello', 'HelloController@index');
21Route::post('/hello', 'HelloController@post');
app/Http/Controllers/HelloController.php
(※php artisan make:controller HelloControllerで作成)
php
1<?php
2
3namespace App\Http\Controllers;
4
5use Illuminate\Http\Request;
6use Log;
7
8class HelloController extends Controller
9{
10 public function index (Request $request)
11 {
12 return view('hello');
13 }
14 public function post (Request $request)
15 {
16 $request->validate([
17 'post_image1' => 'file|image|max:10000',
18 ]);
19 if ($request->file('post_image1')->isValid()) {
20 Log::info(print_r($request->file('post_image1'), true));
21 $filename = $request->file('post_image1')->store('public/img/post');
22 }
23 return view('hello');
24 }
25}
resources/views/hello.blade.php
php
1<form method="post" action="" enctype="multipart/form-data">
2{{ csrf_field() }}
3<input type="file" name="post_image1">
4<input type="submit" value="変更する">
5</form>
でstorage/app/public/img/postにファイルできました・・・エラー出てないようなので書き込み権限とかは関係なさそうですよね・・・。
回答になってないかもしれませんがご参考までに。