IIS Server Technology WordPress

WordPress on IIS with php_gd2.dll vs php_gd.dll

php.ini php_gd setting

WordPress on IIS with image issues caused by…you guessed it php_gd2.dll or is it php_gd.dll?

php.ini php_gd setting
php_gd2 or php_gd

I, like you and so many others run into technical issues. In this case, I was unable to rotate or edit an image I had uploaded. But for me in this instance, the fix wasn’t too hard. Here is what I did, but before I get there just some basic info.

Current Setup

  • IIS10
  • PHP8.+

If you have those two, then here is how to fix not being able to rotate or edit an image in WordPress…

  1. Open PHP.INI, usually located in your PHP folder.
  2. Check to see if you have this:
  3. Double check that it does NOT have a ” ; ” – if it does, remove it. Having a semicolon tells php not to use it.
  4. Go to your EXT or extension folder within the PHP folder.
  5. Find php_gd, in my case, I did not have php_gd2.dll I had php_gd.dll, if you have php_gd.dll then we were in the same boat and we can go to step 6. IF YOU have php_gd2.dll or no php_gd2.dll read more here.
  6. IF you have php_gd.dll go back to your PHP.INI file and update the file or verify the file has the “2” that had to be removed from the PHP.INI file
  7. Save the PHP.INI file and close it.
  8. Restart your IIS server.
  9. Refresh your browser and try to edit an image. It worked for me, and I hope it can work for you!

And there you have it, a simple chop of “2” in your PHP.INI, and you are all set. Hopefully, it was that easy for you too!

You may also like...