new DB helper; rewritten class.database.php; addition to wb2compat.php