RE: [PHP] Strings
| From: | Javier Morquecho Morquecho | Date: | Thu, 26 Oct 2000 15:28:31 +0000 |
| Subject: | RE: [PHP] Strings | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-22150@lists.php.net to get a copy of this message | ||
I thing not, but I use :
// for (i=1;i<=str.length;i++)
// {
// aux = str.charAt(i - 1);
// if ((aux>0) || (aux<=9)) {}
// else
// {
// alert("field"+desc+" should be a number");
// cual.value="";
// return;
// }
// }
Ing. J@vier Morquecho Morquecho
Cedetel
Desarrollo de proyectos comerciales
Tel : 177-10-87
Cel : 177-00-87
e-mail : jmorquec@cedetel.com.mx
e-movil : 5281770087@emovil.cedetel.com.mx
Home Cedetel : http://www.cedetel.com.mx
"#define QUESTION ((bb) || !(bb)) // Shakespeare"
-----Mensaje original-----
De: Martin [mailto:martin@thomatechnik.de]
Enviado el: Jueves 26 de Octubre de 2000 4:14 AM
Para: php-general@lists.php.net
Asunto: Re: [PHP] Strings
You can use ereg of course, but it's easyer to use is_numeric. Search
the manual.
Martin
Jan van Schaijk wrote:
>
> Hi,
>
> I want to test if a string contains
>
> a) Characters like a-z or A-Z and
> b) numbers like 0-9...
>
> Is there a function that can do this easily?
>
> Jan
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
For additional commands, e-mail: php-general-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net