The method of installing pgsql extension in php
This article mainly explains the "php installation pgsql extension method", the article explains the content is simple and clear, easy to learn and understand, the following please follow the editor's train of thought slowly in depth, together to study and learn "php installation pgsql extension method"!
This article operating environment: windows10, php 7, thinkpad T480 computer.
The specific steps to install the pgsql extension are as follows:
Find the pgsql library in the ext directory of the php source code package, change the directory to pgsql, find phpize (under the bin folder under the php installation directory) and execute the following command:
# / usr/bin/phpize#. / configure-- with-php-config=/usr/bin/php-config finds the php-config location # make & & make install
If all goes well, you will find / usr/local/php/lib/php/extensions/no-debug-non-zts-20151012/ there will be two more pdo_pgsql.so and pgsql.so here.
In the Apache:php configuration file, remove the previous ones related to pgsql, and | restart Apache | phpinfo (); at this time, it is found that it has been extended.
Add extengsions= "pgsql.so" to the Nginx:php configuration file, and | restart Nginx | phpinfo (); at this time, it is found that it has been extended.
Thank you for your reading, the above is the content of "php install pgsql extension", after the study of this article, I believe you have a deeper understanding of the method of installing pgsql extension on php, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!