new mysqli object is null using -'php,mysql,mysqli'

new mysqli object is null  using -'php,mysql,mysqli'

I'm trying to create a connection to a MySQL database using Mysqli in PHP. When I execute the following code on a stand alone page:

ini_set('display_errors', 'On');

$link = new mysqli('localhost', 'myuser', 'mypass', 'dbname');

All I get outputted is an empty Mysqli object where all the properties are null. No error or anything gets displayed.

I also don't see any entries in the Apache or MySQL logs. I'm kind of at a lost on this one.

asked Sep 7, 2015 by rajesh
0 votes

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:
To avoid this verification in future, please log in or register.