5

"PHP Fileinfo extension must be installed/enabled to use Intervention Image " This error message is showing when I was upload image on my shared hosting. Then I was modified my php.ini file using .htaccess file.

Now my .htaccess file looks like,

<IfModule mod_rewrite.c>
<IfModule mod_negotiation.c>
    Options -MultiViews
</IfModule>

RewriteEngine On

# Redirect Trailing Slashes...
RewriteRule ^(.*)/$ /$1 [L,R=301]

# Handle Front Controller...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^ index.php [L]
<IfModule mod_suphp.c>
    suPHP_ConfigPath /home/username/public_html/subfolder
    </IfModule>    
    </IfModule>

subfolder(in .htaccess file) is the laravel project where I want to serve my application.

For enable the PHPFileinfo I was wrote those code in php.ini file(in the project root)

extension=fileinfo.so
extension=pdo.so
extension=pdo_mysql.so

But it doesn't work in my shared hosting!!

How can I solve it?

Inspire Shahin
  • 414
  • 2
  • 8
  • 24

3 Answers3

6

You can enable fileinfo extension from cpanel 1 Go to SOFTWARE=>Select PHP Version=>fileinfo check box and enable fileinfo extension.enter image description here

Samar Gurjar
  • 221
  • 4
  • 10
2

Your host provider need to have the extension file in their php config so it can't be done from your side .

liamvictor
  • 3,251
  • 1
  • 22
  • 25
Alireza
  • 1,706
  • 16
  • 23
1

You can enable fileinfo extension from cpanel 1 .Go to SOFTWARE=> 2. Select PHP Version=>fileinfo check box and enable fileinfo extension. 3. refresh your website and thats all.