I need to validate pan number and bank account number fields. How can I do that using php? I have to implement this validation in civicrm custom form. civicrm has any built in function for these two validations.
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
Pan number validation regular expression
if (!preg_match("/^([a-zA-Z]){5}([0-9]){4}([a-zA-Z]){1}?$/", $pannumber)) {
echo "Invalid pan number";
}