I am simply trying to compare a value entered into a form, to ensure it begins with a ? mark.
I have tried suggestions I could find online but can't seem to get it to see when the ? is missing
Any suggestions or direction would be greatly appreciated.
if(!preg_match("/[\s]*(?)/i", $clean_user_aff_code)){
$user_aff_code_error = "Your Affiliate code MUST begin with a ?";
$message = 'Please Correct Highlighted Entry Errors';
}
if(!preg_match("/^[[:space:]]*?/i", $clean_user_aff_code)){
$user_aff_code_error = "Your Affiliate code MUST begin with a ?";
$message = 'Please Correct Highlighted Entry Errors';
}
Thanks
Douglas