"Shawn Wilson" <sh***@glassgiant.com> wrote in message
news:40***************@glassgiant.com...
"Josip Maslać" wrote:
I need a regular expr. that would match any expresion that doesn't start
with some words (not letters - words!)
For example - reg. expr. that matches any expression that doesn't start
with words 'one' and 'two' ??
if (!preg_match("/^(one|two)/", $foo)) {
//do stuff
}
Many thanks, but that is not really what I'm looking for.
Like I said, I need just a reg. expression(!) that does what I need - not a
work a round like this (solving it with !preg_match()).
My question was just a part of the problem I need to solve, so this solution
doesn't work for me.
What I need is something like negating the class but on strings:
for example:
'/^[^ot]/' - matches all expressions that doesn't start with o or t,
I need something like that but one whole string, not just letters.
thanks