--- sites/all/modules/cck_address_extensions/india/cck_address_india.module 2008-03-18 19:20:25.000000000 +0530 +++ sites/all/modules/cck_address_extensions/india/cck_address_india.module.NEW 2008-03-18 19:32:53.000000000 +0530 @@ -160,7 +160,7 @@ function cck_address_india_validate_addr if (($item['city'] != '') && (!preg_match("/^[\.\'\-[:alpha:]\s]+$/", $item['city']))) { $errors['city'] = t('(India):Illegal value for %name\'s City field. Only letters, \' and - are valid. No numbers or other special characters allowed.', array('%name' => $field_name)); } - if (($item['zip'] != '') && (!preg_match("^[1-9]{3}\s{0,1}[0-9]{3}$", $item['zip']))) {//zip code is 6 digits with a possible space after third. first set is 1-9, second is 0-9 + if (($item['zip'] != '') && (!preg_match("/^[1-9]{1}[0-9]{2}\s{0,1}[0-9]{3}$/", $item['zip']))) { // zip code is 6 digits with a possible space after third. first digit is 1-9, next 2 digits are 0-9, followed by an optional space and 3 digits in the set [0-9] $errors['zip'] = t('(India):Illegal value for %name\'s ZIP field.', array('%name' => $field_name)); } if (($item['other'] != '') && (!preg_match("/^[\.\'\-[:alpha:]0-9\s]+$/", $item['other']))) {