i wrote extension.
ubuntu system.
php -c "/etc/php5/apache2/php.ini" -r "echo extension_loaded('my');" => 1 ok!
but under apache - nothing!
echo extension_loaded('my'); => ""
why?
php ini shows:
"loaded configuration file /etc/php5/apache2/php.ini"
i put extensions in separate files , place them inside
/etc/php5/apache2/conf.d/
suppose wanted load mongo php extension, perform following steps:
sudo pecl install mongo
and once completed successfully, make a
echo "extension=mongo.so" | sudo tee /etc/php5/apache2/conf.d/mongo.ini
after reload or restart server
sudo service apache2 restart
Comments
Post a Comment