Im just doing some regular expression searches on a string.
The string is a list of numbers, seperated by a comma. For example
$string = "4,5,12,22,32,2"';
now, i need to search that string for a number, lets say '2'. I need to search that string and ONLY return '2' as a result. I cannot have the code saying there is a match if it matches the '2' in '12' or '22'. Make sense?
Ideas on a postcard please.