I am looking for a way in which I can check a variable is in a certain list of values.
What i am doing is taking a country then checkin whether it is in a certain group e.g. continent etc.
Now i know i can do this:
Code: Select all
if ($cn = UK || $cn = SP || $cn = FR || $cn =GER || ..etc.....
print ' European country';but i wondered whether there is a quicker way to achieve this in code
Thanks in advance