Install PHP ldap in cPanel
You can install PHP ldap using the following steps.
First, you need to make sure you have the openldap-devel RPM installed for your system. If it is not installed you can simply install it by using the following command.
yum install openldap-devel
Steps: EasyApache3
Do the following steps if you are using EasyApache3.
mkdir /var/cpanel/easy/apache/rawopts/ cd /var/cpanel/easy/apache/rawopts/ vim all_php5
and add the following to it.
--with-ldap
Then run EasyApache without changing anything, and it will compile ldap into PHP.
/scripts/easyapache --build
You can verify the ldap module is installed on PHP by the following command.
php -m | grep ldap
Steps: EasyApache4
EasyApache 4 comes with multiple PHP support hence we need to enable install PHP ldap on your desired version using the following method.
PHP 5.4
If you would like to install PHP ldap module on PHP 5.4, please run the following command:
yum install ea-php54-php-ldap
PHP 5.5
To install PHP ldap module on PHP 5.5, please run the following command:
yum install ea-php55-php-ldap
PHP 5.6
Run the following command for installing PHP ldap module on PHP 5.6:
yum install ea-php56-php-ldap
PHP 7.0
Run the following command for installing PHP ldap module on PHP 7.0:
yum install ea-php70-php-ldap
PHP 7.1
Run the following command for installing PHP ldap module on PHP 7.1:
yum install ea-php71-php-ldap
That’s it!
If you like this post and wish to receive more articles from us, please like our FB page: Grepitout
Your suggestions and feedbacks will encourage us and help to improve further, please feel free to write your comments.
For more details on our services, please drop us an E-mail at info@grepitout.com
[…] Install PHP ldap in cPanel Server – … – Install PHP ldap in cPanel. You can install PHP ldap using the following steps. First you need to make sure you have the openldap-devel RPM installed for your system. […]