installing maatwebsite/excel with Laravel 9 but getting phpoffice and PHP version issues. I am using PHP 8.1, I downgrade to PHP 8.0 but still doesn’t work. Even I enable the gd extention from the php.ini file.
I am installing maatwebsite using below command which is offered by official website
composer require maatwebsite/excel
2
Answers
I found the problem it's happening due to cache problem, we need to update the cache version.
Let me explain it with all steps
before
after
if the above version is not work for you try it with 1.0 version (optional)
Then install maatwebsiteexcel
It will work like a charm
This will help you
Some time composer require fails on Laravel 9 because of the simple-cache dependency, you will have to specify the psr/simple-cache version as ^1.0 in your composer.json to satisfy the PhpSpreadsheet dependency.
find solution here https://docs.laravel-excel.com/3.1/getting-started/installation.html