You are here

private static function IbanValidator::bigModulo97 in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony/validator/Constraints/IbanValidator.php \Symfony\Component\Validator\Constraints\IbanValidator::bigModulo97()
1 call to IbanValidator::bigModulo97()
IbanValidator::validate in vendor/symfony/validator/Constraints/IbanValidator.php
Checks if the passed value is valid.

File

vendor/symfony/validator/Constraints/IbanValidator.php, line 283

Class

IbanValidator
@author Manuel Reinhard <manu@sprain.ch> @author Michael Schummel @author Bernhard Schussek <bschussek@gmail.com>

Namespace

Symfony\Component\Validator\Constraints

Code

private static function bigModulo97($bigInt) {
  $parts = str_split($bigInt, 7);
  $rest = 0;
  foreach ($parts as $part) {
    $rest = ($rest . $part) % 97;
  }
  return $rest;
}