public static function GetInstance($connenctionType = 'readonly') { if (!isset(self::$mInstance) || self::$mInstance->mConnenctionType != $connenctionType) { $thisClass = __CLASS__; self::$mInstance = new $thisClass($connenctionType); } return self::$mInstance; }
public static function Close() { if (is_resource(self::$mConnection)) { @mysql_close(self::$mConnection); } self::$mConnection = null; self::$mInstance = null; }