How to enable MySQLi extension for PHP in htaccess? Is it even possible to enable PHP extensions through htaccess file?
You don't.
Mysqli should be installed as a PHP-module and loaded through php.ini
.
Assuming you use a debian-related Linux distribution, this can be done by issuing apt-get install php5-mysqli
.
If this is not an option, please read the PHP documentation on this module and follow the steps described there.
The extension= directive is only valid in the central php.ini
, it cannot be set from within .htaccess files.
At best you could load it manually in your PHP script:
<?php
dl("mysqli.so");
Only works until PHP 5.2
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.