For example, I'd like something like this:
$db = new DBCLASS($host,$user,$pass,$database);
if( $results = $db->query($sql,$table) ) {
//do some stuff
}
else {
//exit
}
With this the errors would be handled by the query function instead of writing the lines for the error handling for every call.
Any thoughts?