validation for integer and float values in php
<p>Im checking for validation for both integer and float.
preg('/^[0-9]+(.[0-9]+)?$/',$str)
This works fine
12,12.05
But not for .12</p>

<p>Any suggestions?</p>

<p>Thanks in advance,
kumar.</p>
