Re: [PHP] Regex for telephone numbers

2010-12-31 Thread Daniel P. Brown
On Fri, Dec 31, 2010 at 19:09, Jim Lucas wrote: > > Actually... > > Specified here [1] it says that the {1,} is the same as '+'.  I think you > should > drop the comma.  If you don't this would be valid 844-2345-123456 > > ^[2-9]{1,}[0-9]{2,}\-[2-9]{1,}[0-9]{2,}\-[0-9]{4,}$ > > should be > > ^[2-

Re: [PHP] Regex for telephone numbers

2010-12-31 Thread Jim Lucas
On 12/29/2010 4:35 PM, Daniel P. Brown wrote: > On Wed, Dec 29, 2010 at 19:12, Ethan Rosenberg wrote: >> Dear List - >> >> Thank you for all your help in the past. >> >> Here is another one >> >> I would like to have a regex which would validate that a telephone number >> is in the format xxx

Re: [PHP] memory usage/release & GC

2010-12-31 Thread Tommy Pham
On Fri, Dec 31, 2010 at 2:02 AM, Peter Lind wrote: > > On Dec 31, 2010 6:20 AM, "Tommy Pham" wrote: >> >> Hi folks, >> >> With the recent thread about password & security, I wrote a small quick >> script to generate a random or all possible passwords based on certain >> parameters for a brute for

Re: [PHP] Regex for telephone numbers

2010-12-31 Thread Steve Staples
On Wed, 2010-12-29 at 19:35 -0500, Daniel P. Brown wrote: > On Wed, Dec 29, 2010 at 19:12, Ethan Rosenberg wrote: > > Dear List - > > > > Thank you for all your help in the past. > > > > Here is another one > > > > I would like to have a regex which would validate that a telephone number > >

Re: [PHP] Regex for telephone numbers

2010-12-31 Thread Daniel Brown
On Fri, Dec 31, 2010 at 12:05, Dmitriy Ugnichenko wrote: > I guess, this will work fine > > ereg('[0-9]{3}-[0-9]{3}-[0-9]{4}',  $phone_number); Not quite. Plus, all ereg* functions have been deprecated for some time now. -- Network Infrastructure Manager Documentation, Webmaster Teams htt

Re: [PHP] Regex for telephone numbers

2010-12-31 Thread Dmitriy Ugnichenko
I guess, this will work fine ereg('[0-9]{3}-[0-9]{3}-[0-9]{4}', $phone_number); On Thu, Dec 30, 2010 at 2:12 AM, Ethan Rosenberg wrote: > Dear List - > > Thank you for all your help in the past. > > Here is another one > > I would like to have a regex which would validate that a telephone

Re: [PHP] goto - My comments

2010-12-31 Thread Govinda
Would you please look at the code you wrote again. I must have botched it, because both the age and kitten form still are on the same page. The age page should appear, the data should be accepted and then the kitten page should appear. Ethan Hi Ethan, I don't mean to get in between yo

Re: [PHP] Regex for telephone numbers

2010-12-31 Thread Daniel P. Brown
On Fri, Dec 31, 2010 at 11:04, Per Jessen wrote: > > AFAIK, they too vary from country to country.  Swiss mobile numbers are > 07[6789] NNN, the latter usually written as NNN NN NN, but also > often in a way that will help remembering the number. > Danish mobile#s are the same as land line num

Re: [PHP] Re: Regex for telephone numbers

2010-12-31 Thread Per Jessen
Al wrote: > > > On 12/29/2010 7:12 PM, Ethan Rosenberg wrote: >> Dear List - >> >> Thank you for all your help in the past. >> >> Here is another one >> >> I would like to have a regex which would validate that a telephone >> number is in the format xxx-xxx-. >> >> Thanks. >> >> Ethan >>

Re: [PHP] Regex for telephone numbers

2010-12-31 Thread Per Jessen
a...@ashleysheridan.co.uk wrote: > Sorry for top-post, on phone. > > What about mobile phone numbers (cell phones you call them in the US) > do they conform to the same format? AFAIK, they too vary from country to country. Swiss mobile numbers are 07[6789] NNN, the latter usually written a

Re: [PHP] Re: Regex for telephone numbers

2010-12-31 Thread Al
On 12/31/2010 11:10 AM, a...@ashleysheridan.co.uk wrote: Erm, you say regex is overkill, then use one in your example! Thanks, Ash http://www.ashleysheridan.co.uk - Reply message - From: "Al" Date: Fri, Dec 31, 2010 15:53 Subject: [PHP] Re: Regex for telephone numbers To:, On 12/29

Re: [PHP] Re: Regex for telephone numbers

2010-12-31 Thread a...@ashleysheridan.co.uk
Erm, you say regex is overkill, then use one in your example! Thanks, Ash http://www.ashleysheridan.co.uk - Reply message - From: "Al" Date: Fri, Dec 31, 2010 15:53 Subject: [PHP] Re: Regex for telephone numbers To: , On 12/29/2010 7:12 PM, Ethan Rosenberg wrote: > Dear List - > > Th

[PHP] Re: Regex for telephone numbers

2010-12-31 Thread Al
On 12/29/2010 7:12 PM, Ethan Rosenberg wrote: Dear List - Thank you for all your help in the past. Here is another one I would like to have a regex which would validate that a telephone number is in the format xxx-xxx-. Thanks. Ethan MySQL 5.1 PHP 5 Linux [Debian (sid)] Regex i

Re: [PHP] Regex for telephone numbers

2010-12-31 Thread Nathan Rixham
Ethan Rosenberg wrote: At 07:11 AM 12/31/2010, Nathan Rixham wrote: Ethan Rosenberg wrote: FYI [to all the list] -- I thank all for their input. I only needed US phones, and I am forcing the user of the form to conform to xxx-xxx- as the input format. out of interest, why are you forcin

Re: [PHP] Job Search

2010-12-31 Thread Greg Bair
On Fri, 31 Dec 2010 09:11:31 -0500 Ethan Rosenberg wrote: > Dear list - > > I am an entry level data base programmer [PHP/MySQL HTTP/CSS] looking > for work in the NY metropolitan area. Any ideas? > > Should we have a job search board? > > Ethan phpdeveloper.org has a nice job board at http

Re: [PHP] Job Search

2010-12-31 Thread Daniel Brown
On Fri, Dec 31, 2010 at 09:11, Ethan Rosenberg wrote: > Dear list - > > I am an entry level data base programmer [PHP/MySQL HTTP/CSS] looking for > work in the NY metropolitan area.  Any ideas? Search Google, but trust me, you're going to need more experience than entry-level to pick up a job

Re: [PHP] Regex for telephone numbers

2010-12-31 Thread Ethan Rosenberg
At 09:27 AM 12/31/2010, a...@ashleysheridan.co.uk wrote: Sorry for top-post, on phone. What about mobile phone numbers (cell phones you call them in the US) do they conform to the same format? I know there have been times myself when I've been without a landline number leaving me with only my

Re: [PHP] Regex for telephone numbers

2010-12-31 Thread a...@ashleysheridan.co.uk
Sorry for top-post, on phone. What about mobile phone numbers (cell phones you call them in the US) do they conform to the same format? I know there have been times myself when I've been without a landline number leaving me with only my mobile as a means of contact. Thanks, Ash http://www.ashle

[PHP] Job Search

2010-12-31 Thread Ethan Rosenberg
Dear list - I am an entry level data base programmer [PHP/MySQL HTTP/CSS] looking for work in the NY metropolitan area. Any ideas? Should we have a job search board? Ethan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Regex for telephone numbers

2010-12-31 Thread Ethan Rosenberg
At 07:11 AM 12/31/2010, Nathan Rixham wrote: Ethan Rosenberg wrote: FYI [to all the list] -- I thank all for their input. I only needed US phones, and I am forcing the user of the form to conform to xxx-xxx- as the input format. out of interest, why are you forcing you're users to confor

Re: [PHP] Regex for telephone numbers

2010-12-31 Thread Nathan Rixham
Ethan Rosenberg wrote: FYI [to all the list] -- I thank all for their input. I only needed US phones, and I am forcing the user of the form to conform to xxx-xxx- as the input format. out of interest, why are you forcing you're users to conform to that input format? you could simply stri

Re: [PHP] Re: Do you trim() usernames and passwords?

2010-12-31 Thread Nathan Rixham
Tamara Temple wrote: Sorry, I was mislead by your use of the phrase "Users should not be copy-pasting passwords or usernames" above. I'd love to hear what you think is an alternative to identifying with web app that keeps track of information about someone that is more secure. client side ssl

Re: [PHP] Re: Do you trim() usernames and passwords?

2010-12-31 Thread Nathan Rixham
Tamara Temple wrote: On Dec 28, 2010, at 2:11 PM, Joshua Kehn wrote: Specifically: Dotan Cohen wrote: I seem to have an issue with users who copy-paste their usernames and passwords coping and pasting leading and trailing space characters. Users should not be copy-pasting passwords or use

Re: [PHP] memory usage/release & GC

2010-12-31 Thread Peter Lind
On Dec 31, 2010 6:20 AM, "Tommy Pham" wrote: > > Hi folks, > > With the recent thread about password & security, I wrote a small quick > script to generate a random or all possible passwords based on certain > parameters for a brute force use. On a very long running execution for a > complex pass