'How to install/enable GD in xampp windows [php 7.2]?
I Can't figure out how to install php-gd for PHP7.2. Is there any way to install/enable GD extension in xampp windows? I checked the php.ini file for php_gd2.dll but I can't find that line. It seems like GD is missing in PHP7.2. Any suggestions??
Solution 1:[1]
- go to php.ini file
- search this
;extension=gd - remove
;then restart the server
Solution 2:[2]
Under xampp/php/php.ini look for "extension=gd2" and uncomment it, I presume this what you looking for
Solution 3:[3]
8 steps:
- Open xampp control panel.
- Start apache and mysql.
- Click on config option of apache.
- Click on php.ini and open it.
- Press Ctrl+F and search "extension=" or "extension=fileinfo".
- On the next line to "extension=fileinfo", add "extension=gd".
- Save the file.
- Stop apache and restart it.
You are done.
My PHP version is 8. if yours is 7 you may need to add extension=gd2 in php.ini file.
You can see your PHP version by searching for "localhost/dashboard" in the browser and then clicking on "PHPinfo" at the top right.
if ";extension=gd" is already there, remove the semicolon and save the file and restart Xampp.
Solution 4:[4]
- open XAMPP control panel
- click Apache config select PHP(php.ini)
- ctrl + F , so search for gd
- you should see a line like
;extension=gd - just remove
;and save it - stop apache and restart
- Your XAMPP now has GD enable
Solution 5:[5]
I had to add the absolute path to the extension as well:
extension=gd
extension=C:\xampp\php\ext\php_gd.dll
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | N69S |
| Solution 2 | marcovie |
| Solution 3 | zx485 |
| Solution 4 | infomasud |
| Solution 5 | Tyler2P |
