Re: [PHP] regular expressions question

2008-03-07 Thread Richard Lynch
.net > Sent: Tuesday, March 4, 2008 3:09:09 PM > Subject: Re: [PHP] regular expressions question > > On Tue, March 4, 2008 1:19 pm, Adil Drissi wrote: >> Is there any way to limit the user to a set of characters for >> example >> say i want my user to enter any character b

Re: [PHP] regular expressions question

2008-03-05 Thread Robert Cummings
k fields. > > Thank you > > - Original Message > From: Richard Lynch <[EMAIL PROTECTED]> > To: Adil Drissi <[EMAIL PROTECTED]> > Cc: php-general@lists.php.net > Sent: Tuesday, March 4, 2008 3:09:09 PM > Subject: Re: [PHP] regular expressions question &g

Re: [PHP] regular expressions question

2008-03-05 Thread It Maq
t;[EMAIL PROTECTED]> To: Adil Drissi <[EMAIL PROTECTED]> Cc: php-general@lists.php.net Sent: Tuesday, March 4, 2008 3:09:09 PM Subject: Re: [PHP] regular expressions question On Tue, March 4, 2008 1:19 pm, Adil Drissi wrote: > Is there any way to limit the user to a set of characters for exa

Re: [PHP] regular expressions question

2008-03-04 Thread Adil Drissi
Thank you guys, The answers you gave me not only solved the problem, but i included more characters like space and -. Thank you again --- Richard Lynch <[EMAIL PROTECTED]> wrote: > On Tue, March 4, 2008 1:19 pm, Adil Drissi wrote: > > Is there any way to limit the user to a set of > characters

Re: [PHP] regular expressions question

2008-03-04 Thread Richard Lynch
On Tue, March 4, 2008 1:19 pm, Adil Drissi wrote: > Is there any way to limit the user to a set of characters for example > say i want my user to enter any character between a and z (case > insensitive). And if the user enters just one letter not belonging to > [a-z], this will not be accepted. > >

Re: [PHP] regular expressions question

2008-03-04 Thread Daniel Brown
On Tue, Mar 4, 2008 at 2:19 PM, Adil Drissi <[EMAIL PROTECTED]> wrote: > Hi, > > Is there any way to limit the user to a set of characters for example say i > want my user to enter any character between a and z (case insensitive). And > if the user enters just one letter not belonging to [a-z],

Re: [PHP] regular expressions question

2008-03-04 Thread David Giragosian
On 3/4/08, Adil Drissi <[EMAIL PROTECTED]> wrote: > Hi, > > Is there any way to limit the user to a set of characters for example say i > want my user to enter any character between a and z (case insensitive). And > if the user enters just one letter not belonging to [a-z], this will not be > ac

Re: [PHP] regular expressions question

2002-10-30 Thread jla21
Whoops.. I missed one bit. Rasmus did it right. ;) On Wed, 30 Oct 2002 [EMAIL PROTECTED] wrote: > If I understand you correctly, I think you want this? > > $matches = array(); > $test = "(this)example"; > preg_match("/\((.*)\)(.*)/", $test, $matches); > array_shift($matches); > > On Wed, 30 Oc

Re: [PHP] regular expressions question

2002-10-30 Thread jla21
If I understand you correctly, I think you want this? $matches = array(); $test = "(this)example"; preg_match("/\((.*)\)(.*)/", $test, $matches); array_shift($matches); On Wed, 30 Oct 2002, Simon Dedeyne wrote: > I have a little question. I'm having some difficulty with regular > expressions: >

Re: [PHP] regular expressions question

2002-10-30 Thread Rasmus Lerdorf
$str = "(this)example"; preg_match("/\((.*?)\)(.*)/",$str,$regs); $a[0] = $regs[1]; $a[1] = $regs[1].$regs[2]; On Wed, 30 Oct 2002, Simon Dedeyne wrote: > I have a little question. I'm having some difficulty with regular > expressions: > > here it is: > (this)exam