Skip to content

EuVatIdValidator ​

Type
Class
Namespace
craft\commerce\taxidvalidators
Inherits
craft\commerce\taxidvalidators\EuVatIdValidator
Implements
craft\commerce\base\TaxIdValidatorInterface
Since
5.3.0

EuVatIdValidator checks if a given VAT ID is valid in the EU.

Valid Test number: PL7272445205

View source

Public Methods ​

MethodDescription
__construct()
displayName()
isEnabled()Tests if the validator is available for use by tax rates.
validate()
validateExistence()
validateFormat()

__construct() ​

View source

displayName() ​

View source

isEnabled() ​

Since
5.3.0

Tests if the validator is available for use by tax rates.

This would usually be a check against the existence or settings or API keys so that the validator can be used.

View source

Returns ​

boolean

validate() ​

View source

Arguments ​

  • $idNumber

validateExistence() ​

View source

Arguments ​

  • $idNumber

validateFormat() ​

View source

Arguments ​

  • $idNumber