The problem is when I tried to create a new app it kept showing lists of problems and did not create the application properly. When I use artisan serve nothing happens
The problem is caused by the lack of the fileinfo extension.
In new versions of PHP, this extension is bundled with installation, but on Windows devices, you must enable this extension inside your php.ini configuration file.
Open the file php.ini file in the directory (C:Program Filesphp-8.3.4php.ini) and look for the line that looks like this:
;extension=fileinfo
Remove the semicolon so that it becomes like this:
extension=fileinfo
And that’s it, everything should start working normally. In case you get other error messages about missing extensions, just look for them inside your php.ini file and uncomment them, for example, if you get an error message about a missing pdo_sqlite extension then open the php.ini file and remove the comment to enable it:
extension=pdo_sqlite
Note for future readers: You can get the path of the php.ini file being used by running the command php --ini in your terminal, it will tell you the exact location of the file. Here’s an example:
2
Answers
The problem is caused by the lack of the
fileinfo
extension.In new versions of PHP, this extension is bundled with installation, but on Windows devices, you must enable this extension inside your
php.ini
configuration file.Open the file
php.ini
file in the directory (C:Program Filesphp-8.3.4php.ini) and look for the line that looks like this:Remove the semicolon so that it becomes like this:
And that’s it, everything should start working normally. In case you get other error messages about missing extensions, just look for them inside your
php.ini
file and uncomment them, for example, if you get an error message about a missingpdo_sqlite
extension then open thephp.ini
file and remove the comment to enable it:Note for future readers: You can get the path of the
php.ini
file being used by running the commandphp --ini
in your terminal, it will tell you the exact location of the file. Here’s an example:I used composer install –ignore-platform-reqs, works well for me