Commit 95cad2db221548e88ab2e9712c7d817ee1c50978
Committed by
GitHub
Merge pull request #1573 from descipher/master
Add full Canadian postal code validation.
Showing
1 changed file
with
1 additions
and
1 deletions
... | ... | @@ -283,7 +283,7 @@ function Contact($compile, $templateCache) { |
283 | 283 | "Austria": "[0-9]{4}", |
284 | 284 | "Belgium": "[0-9]{4}", |
285 | 285 | "Brazil": "[0-9]{5}[\\-]?[0-9]{3}", |
286 | - "Canada": "[A-Za-z][0-9][A-Za-z] [0-9][A-Za-z][0-9]", | |
286 | + "Canada": "^(?!.*[DFIOQU])[A-VXY][0-9][A-Z][ -]?[0-9][A-Z][0-9]$", | |
287 | 287 | "Denmark": "[0-9]{3,4}", |
288 | 288 | "Faroe Islands": "[0-9]{3,4}", |
289 | 289 | "Netherlands": "[1-9][0-9]{3}\\s?[a-zA-Z]{2}", | ... | ... |