preg_match("/\AThis/m", $multitest); // returns true if the string starts with "This" (true) preg_match("/symbol\z/m", $multitest); // returns true if the string ends with "symbol" (false)