<?php $line = "this is a test!"; if (preg_match("/\bis\b/i", $line, $match)) print "Match found!"; ?>