alohatofu Posted April 22, 2007 Share Posted April 22, 2007 How can I write it so that it will grab anything that is before a certain word. Please reference Remedy ticket #297019Notice ID: Let's say I want anything from the word reference on to but not including anything after the word Notice Quote Link to comment Share on other sites More sharing options...
c4onastick Posted April 23, 2007 Share Posted April 23, 2007 preg_match('/(?<=reference).*?(?=Notice)/', $text, $match); Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.