Home  >  Article  >  Backend Development  >  What to do if the php gd module is not installed

What to do if the php gd module is not installed

藏色散人
藏色散人Original
2021-05-19 09:59:283569browse

How to install the gd module in php: 1. Download the corresponding version of the PHP source code, then decompress and compile and install; 2. Install the gd module through the "yum -y install php-gd" command, and then restart php That’s it.

What to do if the php gd module is not installed

The operating environment of this article: linux5.9.8 system, PHP7.1 version, DELL G3 computer

php install gd module

Method 1: (Unsuccessful, mark first

To download libpng, jpeg, freetype, libXpm. Then

./configure --prefix=...
make && make install

Download the corresponding version of the PHP source code, and then solve it Compression

In the corresponding php-src-xx.xx/ext/gd

phpize
./configure --with-xxx-dir=... .... ...

The compilation is successful, but it cannot be loaded = =Depressed.

Method 2:

yum -y install php-gd

After installation, you can check which modules are available through

php -m

and then restart php.

Recommended learning: "PHP Video Tutorial

The above is the detailed content of What to do if the php gd module is not installed. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn