Home > Backend Development > PHP Tutorial > Nginx and php installation and configuration 5. Linux uses PHPIZE to install PHP GD extension

Nginx and php installation and configuration 5. Linux uses PHPIZE to install PHP GD extension

不言
Release: 2023-03-23 19:32:01
Original
2240 people have browsed it

The content of

article shared with you is about Nginx and PHP installation and configuration. Five, LINUX uses PHPIZE to install PHP GD extension. It has certain reference value. Friends in need can refer to it.

1. Generate so file

【1】sudo yum install php-gd2 png jpeg freetype //YUM install extension

【2】cd /php/ext/gd //php folder is I got it by unzipping the PHP installation package.

【3】phpize ./configure --with-png-dir --with-freetype-dir --with-jpeg-dir --with-gd

【4】./ configure --with-png-dir --with-freetype-dir --with-jpeg-dir --with-gd

【5】sudo make

【6】make install



2. Copy the php.ini file


Introduce the dir of so and open the extension so

extension=gd.so //Add this line and restart the PHP service


##3. Restart Server

Related recommendations:

Nginx and php installation and configuration 4 nginx and php start or restart

Nginx and php installation and Configuration three: nginx configuration file

Nginx and php installation and configuration Two: installation and configuration php-fpm

The above is the detailed content of Nginx and php installation and configuration 5. Linux uses PHPIZE to install PHP GD extension. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template