<?php $sentence = "Locally meet daily newlywed for next 3 days"; // Use preg_match() function to check match preg_match_all('/\b(?!(?:daily|weekly|monthly))(\w+ly)\b/', $sentence, $matches, PREG_OFFSET_CAPTURE); // Display matches result print_r($matches);
You have javascript disabled. You will not be able to edit any code.