Improved error reporting when using 'db_ext' authentication
Added quoting of table and column names when using 'db_ext' authentication
Tidied up quoting of identifiers
Fixed bug when using $db_port with mysql
Removed debugging info when using $db_port with mysqli
Allowed use of non-standard port numbers when using 'db_ext' authentication