$source = ['domain.com', 'subdomain.value.com'];
$str = ['value.com', 'blur.de', 'hey.as'];
How to check if any of $str is present in $source?
I've tried in_array or array_intersect but both seem to check for exact values, so none match.
In this example, it should match as 'value.com' is present in 'subdomain.value.com'.
in_arraybecause there is a bit of extra matching work for the substrings.in_arrayandarray_intersectdo only exact matches. Importantly, to find the right solution-- should"subdomain.value"(or just"value", or just"in.va") match to"subdomain.value.com"?