I have this code and for some reason it just won't give me any errors when I pass in invalid data. At least I would expect to get either wrong database or the standard 'Access denied for user 'root@localhost'
. I have experienced lots of these mystical non-showing errors after I moved to PHP 5.4 and it's getting bothersome. Have I overlooked something really silly here? Any help appreciated.
mysql_connect('localhost', 'wrong', 'wrong') or die(mysql_error());
mysql_select_db('wrong'); or die(mysql_error()); # <--- Somehow a semi-colon appeared inside this line and kept php/mysql from showing errors.
php.ini: display_errors = On, error_reporting = E_ALL
The extra ;
in the line,
mysql_select_db('wrong') or die(mysql_error());