Re: [PHP] ereg() problem

2007-01-31 Thread Jim Lucas
jekillen wrote: Hello php list; I am having trouble with ereg(). The following is the problem code $x = ereg(route name='$to' x='../(.*)/in' rec='.*' /, $get_route, $m); do we need to break out of the text to include the $to variable?? testing $route I get: do you mean $get_route? $route

Re: [PHP] ereg() problem

2007-01-31 Thread jekillen
On Jan 31, 2007, at 8:13 AM, Jim Lucas wrote: jekillen wrote: Hello php list; I am having trouble with ereg(). The following is the problem code $x = ereg(route name='$to' x='../(.*)/in' rec='.*' /, $get_route, $m); do we need to break out of the text to include the $to variable?? The $to

Re: [PHP] ereg() problem

2007-01-31 Thread Richard Lynch
On Tue, January 30, 2007 8:36 pm, jekillen wrote: I am having trouble with ereg(). The following is the problem code $x = ereg(route name='$to' x='../(.*)/in' rec='.*' /, $get_route, $m); testing $route I get: $route = $m[1]; print $route.'br'; jk/in' rec='a_378e6dc4.xml' / (out put of

Re: [PHP] ereg() problem

2007-01-31 Thread Jim Lucas
jekillen wrote: On Jan 31, 2007, at 8:13 AM, Jim Lucas wrote: jekillen wrote: Hello php list; I am having trouble with ereg(). The following is the problem code $x = ereg(route name='$to' x='../(.*)/in' rec='.*' /, $get_route, $m); do we need to break out of the text to include the $to

Re: [PHP] ereg() problem

2007-01-31 Thread Jim Lucas
jekillen wrote: On Jan 31, 2007, at 8:13 AM, Jim Lucas wrote: jekillen wrote: Hello php list; I am having trouble with ereg(). The following is the problem code $x = ereg(route name='$to' x='../(.*)/in' rec='.*' /, $get_route, $m); do we need to break out of the text to include the $to

Re: [PHP] ereg() problem: solution

2007-01-31 Thread jekillen
Hi In reference to my query about 'greed' in regex in php and the following code $x = ereg(route name='$to' x='\.\./(.*)/in' rec='.*' /, $get_route, $m); I solved the immediate problem with the following: route name='$to' x='\.\./([a-z]{2}|a?u_[0-9a-z]{8})/in' rec='.*' / as you can see, the

Re: [PHP] ereg() problem

2007-01-31 Thread jekillen
On Jan 31, 2007, at 4:38 PM, Richard Lynch wrote: On Tue, January 30, 2007 8:36 pm, jekillen wrote: I am having trouble with ereg(). The following is the problem code $x = ereg(route name='$to' x='../(.*)/in' rec='.*' /, $get_route, $m); testing $route I get: $route = $m[1]; print

Re: [PHP] Ereg problem

2006-06-27 Thread Robert Cummings
On Tue, 2006-06-27 at 12:14, Beauford wrote: One more in my recent woes. The last elseif does not work in the code below - even if the string is correct it always says it's incorrect. Even if I remove everything else and just have the ereg satement is doesn't work either. The code below is

Re: [PHP] Ereg problem

2006-06-27 Thread John Nichel
Beauford wrote: Please turn of your mail client's request for return receipts when sending to a mailing list. -- John C. Nichel IV Programmer/System Admin (ÜberGeek) Dot Com Holdings of Buffalo 716.856.9675 [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

RE: [PHP] Ereg problem

2006-06-27 Thread Beauford
-Original Message- From: Robert Cummings [mailto:[EMAIL PROTECTED] Sent: June 27, 2006 12:58 PM To: Beauford Cc: PHP-General Subject: Re: [PHP] Ereg problem On Tue, 2006-06-27 at 12:14, Beauford wrote: One more in my recent woes. The last elseif does not work in the code below

Re: [PHP] ereg problem

2004-03-12 Thread Newman Weekly.
Don't worry about this I worked out that the example was wrong (o; - Original Message - From: Newman Weekly. [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, March 13, 2004 1:59 PM Subject: [PHP] ereg problem ?php $formUserName=foobar; if

Re: [PHP] ereg problem?

2003-07-25 Thread sven
by the way, it's to complicated. the brackets [ and ] are used for cha-groups. you can leave them for only one char. so this would be the same: \\n (you have to escape the backslash with a backslash) Curt Zirzow wrote: * Thus wrote John W. Holmes ([EMAIL PROTECTED]): [EMAIL PROTECTED] wrote:

RE: [PHP] ereg problem?

2003-07-25 Thread Ford, Mike [LSS]
-Original Message- From: sven [mailto:[EMAIL PROTECTED] Sent: 25 July 2003 10:35 by the way, it's to complicated. the brackets [ and ] are used for cha-groups. you can leave them for only one char. so this would be the same: \\n (you have to escape the backslash with a backslash)

Re: [PHP] ereg problem?

2003-07-24 Thread John W. Holmes
[EMAIL PROTECTED] wrote: who can tell me what's the pattern string mean. if(ereg([\\][n],$username)) { /*Do err*/ } It's looking for a \ character or a \ character followed by the letter n anywhere within the string $username. -- ---John Holmes... Amazon Wishlist:

Re: [PHP] ereg problem?

2003-07-24 Thread Curt Zirzow
* Thus wrote John W. Holmes ([EMAIL PROTECTED]): [EMAIL PROTECTED] wrote: who can tell me what's the pattern string mean. if(ereg([\\][n],$username)) { /*Do err*/ } It's looking for a \ character or a \ character followed by the letter n anywhere within the string $username. I

Re: [PHP] ereg problem

2001-02-16 Thread Jeff Warrington
In article [EMAIL PROTECTED], "Janet Valade" [EMAIL PROTECTED] wrote: if you include a hyphen in a character class, it must be the last entry in the range, otherwise it is interepreted as the range separator. [0-9+.\()-] is what you want (probably have to escape some of the chars above).

RE: [PHP] ereg problem

2001-02-15 Thread Maxim Maletsky
- hyphen is something a bit special in RegEx .. read the manual, I think you should escape it. Cheers, Maxim Maletsky -Original Message- From: Janet Valade [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 15, 2001 3:21 AM To: '[EMAIL PROTECTED]' Subject: [PHP] ereg problem I am

Re: [PHP] ereg problem

2001-02-14 Thread CC Zona
In article [EMAIL PROTECTED], [EMAIL PROTECTED] (Janet Valade) wrote: if (!ereg("^[0-9\-\+\.\ \)\(]{10,}$",$value)) { Can anyone tell me why this works for every character except the -. It doesn't see the hyphen as a valid part of the phone number, even though it recognizes the other

Re: [PHP] ereg problem

2001-02-14 Thread Charlie Llewellin
the - needs to be immediately after the [ to include that character. Otherwise it is a range indicator. Charlie - Original Message - From: "CC Zona" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, February 14, 2001 12:56 PM Subject: Re: [PHP] ereg problem In arti

Re: [PHP] ereg problem

2001-02-14 Thread CC Zona
ry 14, 2001 12:56 PM Subject: Re: [PHP] ereg problem In article [EMAIL PROTECTED], [EMAIL PROTECTED] (Janet Valade) wrote: if (!ereg("^[0-9\-\+\.\ \)\(]{10,}$",$value)) { Can anyone tell me why this works for every character except the -. It doesn't see the hyphen as a

RE: [PHP] ereg problem

2001-02-14 Thread Janet Valade
Thank you. That was exactly the problem. Janet -Original Message- From: Charlie Llewellin [SMTP:[EMAIL PROTECTED]] Sent: Wednesday, February 14, 2001 11:00 AM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: [PHP] ereg problem the - needs to be immediately after