src/Registration.php
protected function detectMnc($lc, $carrierName)
  {
      $fp = fopen(__DIR__.DIRECTORY_SEPARATOR.'networkinfo.csv', 'r');
      $mnc = null;

      while ($data = fgetcsv($fp, 0, ',')) {
          if ($data[4] === $lc && $data[7] === $carrierName) {
              $mnc = $data[2];
              break;
          }
      }

      if ($mnc == null) {
          $mnc = '000';
      }

      fclose($fp);

      return $mnc;
  }
protected function detectMnc($lc, $carrierName)
  {
      $fp = fopen(__DIR__.DIRECTORY_SEPARATOR.'networkinfo.csv', 'r');
      $mnc = null;

      while ($data = fgetcsv($fp, 0, ',')) {
          if ($data[4] === $lc && $data[7] === $carrierName) {
              $mnc = $data[2];
              break;
          }
      }

      if ($mnc == null) {
          $mnc = '000';
      }

      fclose($fp);

      return $mnc;
  }
protected function detectMnc ( $ lc , $ carrierName ) { $ fp = fopen ( __DIR__ . DIRECTORY_SEPARATOR . 'networkinfo.csv' , 'r' ) ; $ mnc = null ; while ( $ data = fgetcsv ( $ fp , 0 , ',' ) ) { if ( $ data [ 4 ] === $ lc && $ data [ 7 ] === $ carrierName ) { $ mnc = $ data [ 2 ] ; break ; } } if ( $ mnc == null ) { $ mnc = '000' ; } fclose ( $ fp ) ; return $ mnc ; }
Detects mnc from specified carrier.

@param string $lc          LangCode
@param string $carrierName Name of the carrier

@return string

Returns mnc value
Detects mnc from specified carrier .