Egypt (eg)


Egypt-specific Form helpers.


A Select widget that uses a list of Egypt governorates as its choices.

New in version 3.0.

class, min_length=14, **kwargs)[source]

Egypt ID numbers are 14 digits, second to seventh digits represents the person’s birthdate.

Checks the following rules to determine the validity of the number:
  • The number consist of 14 digits.
  • The century number is valid.
  • The birthdate of the person is a valid date.
  • The governorate code is valid.

New in version 3.0.


Validate the given value and return its “cleaned” value as an appropriate Python object. Raise ValidationError for any errors.