You are here: Re: [PHP] Removing non-numbers « PHP « IT news, forums, messages
Re: [PHP] Removing non-numbers

Posted by Greg Donald on 09/29/74 11:08

On Mon, 14 Feb 2005 18:54:03 -0700, Ben Miller <benipmiller@comcast.net> wrote:
> OK - easy one here, I know. Having troubles removing anything that is not a
> number from user input. According to manual, [!] is supposed to mean set of
> non-matching optional characters.

$var = preg_replace( '/[^\d]/', '', $var );


--
Greg Donald
Zend Certified Engineer
http://destiney.com/

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация