Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
getAdvancedPostalCodePattern example
return
;
}
}
if
(
!
$country
->
getCheckPostalCodePattern
(
)
&& !
$country
->
getCheckAdvancedPostalCodePattern
(
)
)
{
return
;
}
$pattern
=
$country
->
getDefaultPostalCodePattern
(
)
;
if
(
$country
->
getCheckAdvancedPostalCodePattern
(
)
)
{
$pattern
=
$country
->
getAdvancedPostalCodePattern
(
)
;
}
if
(
$pattern
=== null
)
{
return
;
}
$caseSensitive
=
$constraint
->caseSensitiveCheck ? '' : 'i';
if
(
preg_match
(
"/^{
$pattern
}
$/" .
$caseSensitive
,
(string)
$value
,
$matches
)
=== 1
)
{
return
;
}