Re: [PHP-WIN] How to check if a *string* has only numbers...

2004-11-16 Thread Michael Purdy
ke - Original Message - From: "Rafael Soares" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, November 17, 2004 10:36 AM Subject: [PHP-WIN] How to check if a *string* has only numbers... Hello people!!! I would like to check if a string contains o

RES: [PHP-WIN] How to check if a *string* has only numbers...

2004-11-16 Thread Rafael Soares
--- De: Larry E. Ullman [mailto:[EMAIL PROTECTED] Enviada em: terça-feira, 16 de novembro de 2004 23:42 Para: Rafael Soares Cc: [EMAIL PROTECTED] Assunto: Re: [PHP-WIN] How to check if a *string* has only numbers... > I would like to check if a string contains only numbers, I really can’t >

Re: [PHP-WIN] How to check if a *string* has only numbers...

2004-11-16 Thread Larry E . Ullman
I would like to check if a string contains only numbers, I really can’t realize how to do it. is_numeric() $data = $_POST[‘data’]; // something like 123.456.789 $dataParts = explode($data); //these are the variable I have to check: $dataP1 = $dataParts[0]; $dataP2 = $dataParts[1]; $dataP3 = $dataPa

[PHP-WIN] How to check if a *string* has only numbers...

2004-11-16 Thread Rafael Soares
Hello people!!! I would like to check if a string contains only numbers, I really can’t realize how to do it. I tried is_int(), but it don’t work because the variable is a string (I used gettype() to check it) and is_int() returns NULL… It is to validate some data in a form. The variabl