Couple of suggestions...
When going outside the vB DB class, track your new connection by explicitly using the resource identifiers Like...
PHP Code:
mysql_select_db(DB_NAME,$dbc)
mysql_query("SELECT * from NAME_OF_TABLE", $dbc)
After your mysql_free_result you might want to add mysql_close($dbc).
Try putting your ob_end_clean() before your return $output too. Although, I don't see the point of using it. I guess you're trying to catch any errors and tag them on to the output?
I'm not crazy about using constants (DEFINE) for passwords and such either.