bogdy's avatar
Level 10

validation doesnt work for .jpg file

I try to validate a picture with this code.

private $rules = [
    'image' => ['mimes:jpg, jpeg']
  ];

It works for files with extensions .jpeg. but when I upload a .jpg file the image is not displayed.

thanks in advance

0 likes
2 replies
topvillas's avatar

Do you get a validation error? If not then it is working and the problem is somewhere else.

bogdy's avatar
Level 10

I solved the problem :)

thanks

Please or to participate in this conversation.