Re: [Phplib-users] Invalid Regex
Brought to you by:
nhruby,
richardarcher
From: Matt W. <li...@ye...> - 2002-10-31 19:39:35
|
On Thursday 31 October 2002 19:00, Rob Hutton wrote: > This will match 123$abc. It should fail if there are any other charact= ers > besides alphanumeric. I just tried=20 ----------------- $string =3D '123$abc'; if(!eregi("^[a-z0-9]+$",$string)) echo 'no good'; else=20 echo 'you rock'; ----------------- and it outputs ----------------- X-Powered-By: PHP/4.2.1=20 Content-type: text/html=20 =20 no good ---------------- removing the $ outputs as valid unless oohforms is doing something different to it sorry I missed the + off before |