Jamie Saunders wrote:
> 
> ...
> 
> Right, you still with me?  What I'd like to know is how to validate a text
> field in an HTML form to make sure it only contains numbers.  
> 
> ...
> 

Try this:
<?
$phone_nr = '54256009';
if ( ereg( '^[0-9]+$', $phone_nr )) 
        ...ok...
else
        ...not ok...

?>

Hope this helps.

-- 
Pavel a.k.a. Papi

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to