About the CI framework Access database class hints call to undefined function mysqli_init ()

Source: Internet
Author: User
Tags install php php error php framework codeigniter phpmyadmin

Hello everyone, I used to be the practice of ASP, now PHP, but also the codeigniter framework of beginners and practitioners, at that time because of the project, I was forced to play full of chicken blood, passionate choice yii2,lavarel5, CodeIgniter and other PHP framework for project development, as you are "call to undefined function mysqli_init ()" This small problem tortured scratching his ears, looking for the forum still can not find the problem, almost drubbing and return ( At that time I also follow the forum's tips to do, found that there is no use, good fart words not much to say, now by my straight into the topic to say a solution, at the same time said that I was how to solve the above problems.
If you are installing Wampserver 3.0.4 as an integrated development environment, when you install the integration environment, please check localhost/phpmyadmin this background can open, or will report a variety of fatal error, if you encounter fatal Error can only explain a problem, this wampserver is bad!!!, no matter how you configure your project after the dasebase.php file is useless, and the more pit is that the page only shows the call to undefined function mysqli_ Init () This question, no more questions to suggest what you should do.
Until I reinstall the system, after choosing to install Phpstudy, I found that I can actually open phpmyadmin, so I reopen the browser and enter the project URL, found that the page hints of errors and some more content, such as
A PHP Error was encountered
Severity:warning
Message:mysqli::real_connect (): (hy000/1045): Access denied for user ' root ' @ ' localhost ' (using Password:no)
Filename:mysqli/mysqli_driver.php ....
At that time, I also do not know how, I have searched the Internet and refer to the "phpMyAdmin installation and its configuration" article, I found that the database.php in my project was not properly configured, and then after I installed the integrated development environment, maybe you were not configured phpMyAdmin as I did, and thought phpMyAdmin's account was root and the password was empty.
Finally I will$db [' default '] = Array (... ' username ' = ' root ', ' password ' + ' ',...);Switch$db [' default '] = Array (
... ' username ' + ' root ', ' password ' = ' root ',...)。 Reopen the browser and enter the project's url,success (SUCCESS)!!!
Summary: After you install the integrated development environment, please check if the phpMyAdmin daemon can open, but also everyone from other programming languages into the PHP small partners must remember that phpMyAdmin account password is not empty, but root!!! (That is, phpMyAdmin's account name is root and the password is root)

Meet the above problem of the person, I pinch to count, found that there are 80% to 90% may be due to you from other programming development language developed well, but for other reasons are directly into the PHP, as I do, I do not install Php,apache and MySQL, but directly choose, Install and use an integrated development environment such as Wampserver,apmserv, XAMPP, Phpwamp, and so on, there are so many pits hidden behind the integrated development environment waiting for you to solve the lovely.
Encounter call to undefined function mysqli_init () This problem may be the same as I was tortured day and night, re-ignite self-confidence do not know how many times, even re-install the system found that the problem remains intact there, when the gas I fell straight keyboard mouse ( Because the computer is too expensive), shouts to the sun, and even suspicion is not due to the usual self-computer too rough problem.
It is not difficult to learn programming, but it is rare that you want to start before the various, and grotesque, while destroying your self-confidence configuration installation operation, and because of the urgency of time to get started quickly, (really tired wow. Well, I want to say is actually encountered difficulties are not scary, but after encountering difficulties, you find that people give you the time is not very sufficient, and you always can not find the problem solution, and someone has been urging you a few projects to release Wow, Bala,bala, quick fix, I believe your heart is a collapse, as Tianyi's a song The future of the programmer's song The last few words of the same programmer bitter, programmer bitter, programmer bitter, I am a programmer ah ... )
If you see this reply to the partners encounter call to undefined function mysqli_init () This problem still can't solve, can continue to reply this post, you and I explore progress together.

About the CI framework Access database class hints call to undefined function mysqli_init ()

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.