what is preg_match and how can i use it to validate the input field.
in preg_match you can define any pattern for matching the user input.
And then use the preg_match method find the number of matches in it.
<? $pattern = "";// Write regular expression here $string = ""; //Variable to hold user input //use preg_match to find no of matched $count = preg_match($pattern, $string); print $count; //based on the count value you can validate the input ?>
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.