Changes

Jump to: navigation, search

Validating Postal Codes

371 bytes added, 20:53, 3 December 2015
no edit summary
document.frmuser.ucountry.value!="10" || isMatch(@value@, 'LNL NLN', true)
 
==Zip Code Format==
To enforce a US zip code of 5 or 5+4 digits, enter the following into the ''Validation'' setting:
 
isFloat(@value@.replace(/-/g,""),true) && (isMatch(@value@, 'NNNNN', false) || isMatch(@value@, 'NNNNN-NNNN', false))
 
Sample validation message:
 
Zip Code must be in the format of '#####' or '#####-####', example: '32334' or '32334-0092'.
==See Also==
* [[Contact_and_Account_Standard_Fields#Validation|Validating Contact Standard Fields]]
* [[JavaScript Validation]]
* [[Country Codes]] - for the ''value'' to be used for to reference other countries
[[Category:Validation]]
Smartstaff
284
edits

Navigation menu