У меня есть загрузчик, который отлично работает без правил, но когда я создаю правило, я получаю ошибку:
LogicException in MimeTypeGuesser.php line 127:
Unable to guess the mime type as no guessers are available
(Did you enable the php_fileinfo extension?)
Мои правила запроса статьи
/**
* Get the validation rules that apply to the request.
*
* @return array
*/
public function rules()
{
return [
'Image' => 'required|mimes:jpeg'
];
}
Моя форма
{!! Form::open(['url' => 'blog', 'files'=> true]) !!}
<div class="form-group">
{!! Form::label('Image', 'Upload:') !!}
{!! Form::file('Image', null, ['class' => 'form-control']) !!}
</div>
<div class="form-group">
{!! Form::submit('Submit', ['class' => 'btn btn-primary form-control']) !!}
</div>
{!! Form::close() !!}