コード例 #1
0
function um_component_db_connect()
{
    $settings = um_db_load_settings();
    $return = mysql_connect($settings->dbhost, $settings->dbuser, $settings->dbpass);
    mysql_select_db($settings->dbname, $return);
    return $return;
}
コード例 #2
0
function um_client_db_connect(&$settings = NULL)
{
    if (!$settings) {
        $settings = um_db_load_settings();
    }
    //mysql_select_db (DB_NAME);
    mysql_connect($settings->dbhost, $settings->dbuser, $settings->dbpass);
}