I just changed my server and now I'm getting the following error;
Fatal error: Call to undefined function mysqli_init() in /home/site_address/public_html/system/database/drivers/mysqli/mysqli_driver.php on line 125
What's the problem and how to solve it?
Note: changes dbdriver from mysqli to mysql also getting error
Go to your php init file and uncomment the following extension:
extension=php_mysqli.dll
Related
Although calling the same script through browser work fine, trying to trigger the same script via CLI didn't work!
The way I have to call the script I use CodeIgniter structure :
php index.php controller/function/parameter
I have also change in config file of my project:
$config['uri_protocol'] = 'AUTO'
But the problem that oci can't work within cli although it works by calling it using the browser.
THis error appear:
Fatal error: Call to undefined function oci_connect() in C:\wamp64\www\MYPROJECT\syst
em\database\drivers\oci8\oci8_driver.php on line 238
Severity: Error Message: Call to undefined function
oci_connect() Filename:
C:\wamp64\www\MYPROJECT\system\database\drivers\oci8\oci8_driver.php
Line Number: 238
I have enabled the oci extension at php.ini
extension=php_oci8_12c.dll
which is existed in the following directory:
C:\wamp64\bin\php\php5.6.19\ext\php_oci8_12c.dll
I want to connect to oracle database, but i got this error :
"Fatal error: Call to undefined function oci_connect() in C:\xampp81\htdocs\test\inc\db.php on line 75."
I already check php.ini file, and there are 2 lines :
;extension=php_oci8.dll ; Use with Oracle 10gR2 Instant Client
;extension=php_oci8_11g.dll ; Use with Oracle 11gR2 Instant Client
I already remove the (;)
extension=php_oci8.dll ; Use with Oracle 10gR2 Instant Client
Then I restart the apache, but when I start the apache, I got an error:
"error when start apache the procedure entry point OCIPing could not be located in the dynamic link library OCI.dll"
After that I try to login to my website, then i got an error:
"Fatal error: Call to undefined function oci_connect() in C:\xampp81\htdocs\test\inc\db.php on line 75"
Any solution for this case? I already tried to uncomment the extension=php_oci8.dll , but still have an error.
Thank you.
you can also see this answer from this question
here is tutorial of installing oci8 drivers for PHP
https://stackoverflow.com/a/34494636/2125924
The same code works in Xampp. But if try to run it on IIS below error occurs.
"PHP Fatal error: Call to undefined function mysql_connect()"
I'm stuck with this error from couple of days.
I tried changing my php.in . My phpinfo.php points to correct .ini file
Please suggest me a way.
part of my php.ini file:
extension=php_mbstring.dll
extension=php_exif.dll
extension=php_mysql.dll
extension=php_mysqli.dll
extension=php_mysql_libmysql.dll
I am trying to set up phpMyAdmin, and i was following this site , but i got an error about "Fatal error: Call to undefined function mb_detect_encoding() in C:\Users\Jarek\mywebsite\phpMyAdmin\libraries\php-gettext\gettext.inc on line 177", and i searched this error online, Most of suggestion are uncommon some lines in php.ini, but it didn't work for me.
This is the site tell you how to solve problem with this error.
solve 1
solve 2
php.ini is in my php folder which is located in c diver.
prompt command to check path
Every time i changed config, i also did restart apache.
I also tried to write some piece of code of php as below:
$con=mysqli_connect("127.0.0.1","root","xxxxxxx","morris_db");
if (mysqli_connect_errno()) {
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
and open my browser, and type localhost/index.php, it shows me an error about "Fatal error: Call to undefined function mysqli_connect() in C:\Users\Jarek\mywebsite\index.php on line 8"
Try adding these extensions in the PHP.ini
extension=php_mbstring.dll
extension=php_gettext.dll
extension=php_mysql.dll
extension=php_mysqli.dll
extension=php_pdo_mysql.dll
Also check whether the PHP folder exists in the PATH.
I have a magento website. which worked find until my hosting server upgraded its php version to 5.4.25.Now i'm getting this error
Fatal error: Call to undefined function iconv_get_encoding() in /home/dbname/public_html/Magento/mysite/lib/Zend/Validate/Hostname.php on line 520
why i'm getting this error?
You should uncomment extension=iconv.so in php.ini. That would enable the function