OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
RE: virtual.regexp not working

From: Kammen van, Marco, Springer SBM NL (Marco.vanKammenspringer.com)
Date: Wed Jun 03 2009 - 01:55:42 CDT


>> One of our users is requesting a batch of e-mail aliases ranging
from:
>>
>> J10001domain.com to j10300domain.com
>>
>> I made the following regexp which kind of does the trick:
>>
>> /j10[0-3][0-9][0-9]\domain\.com/ thisaddressdomain.com
>>
>> But this adds the range of j10300 to j10399 which isn't wanted.
>> So I tried the following regexp:
>>
>> /j(10001..10300)\domain\.com/ thisaddressdomain.com
>>
>> But that's not working....

>Indeed, since ranges like that simply are not supported in regular
>expressions. This should work:

>/^j10([0-2][0-9][0-9]|300)example\.com$/ thisaddressexample.com

Ofcourse! Guess I mixed up the ranges thing from doing too many Perl
stuff...

This will work just fine....

Thanks!