Sunday, May 26, 2013

PHP OOP DB Connection

$mysqli = new mysqli("localhost","root","","dbname");
if (mysqli_connect_errno())
  {
  echo "Failed to connect to MySQL: " . mysqli_connect_error();
  }

No comments:

Post a Comment