Q. Which of these functions can be used to connect to a MySQL database in PHP?

  • (A) mysqli_connect()
  • (B) mysql_connect()
  • (C) PDO::__construct()
  • (D) All of the above
πŸ’¬ Discuss
βœ… Correct Answer: (D) All of the above
Explanation: mysqli_connect(), mysql_connect() (deprecated), and PDO can all connect to MySQL.
Explanation by: Rati Dubey
mysqli_connect(), mysql_connect() (deprecated), and PDO can all connect to MySQL.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
79
Total Visits
πŸ“½οΈ
1 y ago
Published
πŸŽ–οΈ
Rati Dubey
Publisher
πŸ“ˆ
97%
Success Rate