Check if a String Contains certain text

Let’s say I have a string like so:

“Hi how is it going”

How could I detect if it has the text “is it”

Thanks

strpos()

But be careful, for that will also match within “this item”

To resolve that, you can use preg_match with \b for a word break at the start and end of the text you want to match.