phplaravelfileinfo

can not find *"extension=php_fileinfo.dll"* in my php.ini file?


i tried to insert an image into mysql database but i got that error "Unable to guess the MIME type as no guessers are available (have you enabled the php_fileinfo extension?)."

i only found this extension extension=fileinfo i uncommented it but still getting the same error

i tried to open the php.ini file and i didn't find the "extension=php_fileinfo.dll" then i added it but still got the same error .

anyone faced the same issue please ?


Solution

  • First you need to know where your configuration file is located using

    <?php
    phpinfo();
    ?>
    

    on the sixth-ish line, you have Loaded Configuration File with the file path next to it.

    uncomment/add the extension line in that file (dll for windows)

    extension=php_fileinfo.dll
    

    and restart your server.