Laravel 6.0输入::值“;旧的;
我正在使用此代码,但我没有使用旧函数 我已经使用了这两个Laravel 6.0输入::值“;旧的;,laravel,laravel-6,Laravel,Laravel 6,我正在使用此代码,但我没有使用旧函数 我已经使用了这两个和{{old('title')}都不起作用 <form action="<?php echo route('post.create') ?>" method="GET"> @csrf <input type="text" name="title" value="<?php echo old('ti
和{{old('title')}
都不起作用
<form action="<?php echo route('post.create') ?>" method="GET">
@csrf
<input type="text" name="title" value="<?php echo old('title'); ?>"></br>
<textarea name="contant" id="" cols="30" rows="10"><?php echo old('contant'); ?></textarea>
更改为post
method=“POST”
如果要使用GET方法,请使用request helper函数,而不是旧函数
如果你使用POST方法,但仍然不起作用。几乎没有解决办法
使用withInput()
返回数据
return back()->withInput()->withErrors('Add atleast one image in the post.');
不知道你是否记得,但前几天我提出了一个线程,我的Chrome出现了缓存问题。这也许有道理。我试过金丝雀和同样的问题,所以可能是chrome(如果OP使用的是chrome),请看这篇文章。
欢迎来到SO。。。这是否post.create
使用输入重定向回路由?