title: Detect if mysql or mysqli is being called for connection
body: <p>is there a way to check which type of mysql connection is being called <code>mysql</code> or <code>mysqli</code>. what I want to do is have a If statement to call mysql or mysqli connection until I can change out all my coding. </p>
  
  <p>this is my current connection file. would just duplicating what's below but with mysqli accomplish what i'm trying to do?</p>
  
  <pre><code>$dbc = mysql_connect ($db_server, $db_user, $db_pass);
  mysql_select_db ($db_name) or die(mysql_error());
  
      $g_link = false;
  
      function GetDbConn()
      {
          global $g_link;
          if( $g_link )
              return $g_link;
          $g_link = mysql_connect( 'localhost', 'username', 'password') or die('Could not connect to server.' );
          mysql_select_db('social_db', $g_link) or die('Could not select database.');
          return $g_link;
      }
  
      function CleanUpDB()
      {
          global $g_link;
          if( $g_link != false )
              mysql_close($g_link);
          $g_link = false;
      }
  </code></pre>