January 27th, 2010, 03:12 AM
Negate a complete character set and not one character
if we have to negate a character we do lik
if i want match, say "find b but not starting with word google"
it will negate google by taking alphabeters one by one rather than complete word.
how can i negate the complete word?
January 27th, 2010, 06:51 AM
Do you mean "find b but it can't have the word "google" immediately before it?
Originally Posted by tinystudent
Comments on this post
January 27th, 2010, 01:46 PM
in fact, i want to kill this "immediately" i have a crazy source code i am looking to parse. I have read negative lookahead/lookbehind assertion but still not sure if it is possible with regex what i am looking to do
so i have accepted defeat and after running first regex i will take care of the rest with my lovely php
however for some feed for your brain i have following string(s)
what i am interested is the value that appears with in tag1-pair and SKIP p-tag value IF it does not have a tag1-pair inside it, if it is found then fetch that as well.
additionally, it is possible that tag1 is incorrectly closed, in that i case i must end my search on finding an opening tag1 without closing the previous and make a separate array of such strings so that i can fix those values.
does it make sense?