<?php $str = array( "I like this sentence.", #line1 "I like that sentence.", #line2 "I link THAT sentence." #line3 ); $exp = "/^(?!.*?that).*$/i"; foreach($str as $s) { preg_match_all($exp, $s, $matches); var_dump($matches); }
You have javascript disabled. You will not be able to edit any code.