You are here: Re: validation on amount « PHP Programming Language « IT news, forums, messages
Re: validation on amount

Posted by bobzimuta on 10/24/98 11:44

If you're data will look like '2,10' and you're exploding on the comma
(i.e. array( 0=>2,1=>10) ), it's quicker and easier to use intval() or
is_numeric() on each of the parts. If that doesn't suffice, what
exactly are your constraints (since validation is very important)?

2,00
0,00
1000000000000000000000000000000,00
9,99

Best/easiest way is to split the two values (decimal and whole number)
into separate form values.

 

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

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