If you are WordPress codder and trying to develop a custom built plugin to extend the WordPress functionally and facing database connectivity, then this article really will help for you, here I would explain about WordPress database connection with two different database object.
To make a connection with the WordPress database first we need to ensure we have properly included the WordPress config files which exist into the WordPress root directory.
Step to connect with the database to MySQL:
MySqli is the latest version of the database which is based on object-oriented programming which is far more better than MySQL and fully optimized, so by the time start learning mySqli because since later every web application would start using MySqli instead of MySQL.
Steps Connect Database in WordPress Plugin for MySqli :
Anything else drop a comment please!