Good day to all, I have all day trying to solve how I do to find a match, for example, I have this chain
$txt='1a.10.2a.210.22ac.23acd.24acd'
I must validate that the value 23 is found, next to the letter C for example, but EVERYTHING among the "." the problem is that I deal with the following
preg_match('/(23).*?(c)/', $txt, $output_array);
It does not work, because even if you erase the letter C staying this way
$txt='1a.10.2a.210.22ac.23ad.24acd'
Like the letter C, it is in 24acd , it still finds a match. In summary, you only need to evaluate between the points (.), If the number you enter to search is not found next to the letter or at least between the points (.), It means that you did not find anything.