php newbie question
Normally I work with C# but now I'm playing around with PHP and it's fun. So I type code from books over and try to make some small things of my own.
I've got this piece of code:
$mysqli = new mysqli( 'localhost','root','wrongpassword','sportjegeestgezondblog');
if ($mysqli->errno) echo "unable to connect to database"; else echo "connected";
Where I deliberately give the wrong password but still mysqli->errno keeps returning 0 what am I doing wrong?
