Thank you Sincerely Negin Nickparsa On Sun, Jul 20, 2014 at 11:07 PM, David Harkness <david.h@xxxxxxxxxxxxxxxxx> wrote: > On Sun, Jul 20, 2014 at 5:22 PM, Negin Nickparsa <nickparsa@xxxxxxxxx> > wrote: > >> how PHP rounds the numbers in this case ? >> > > It doesn't use the built-in round function but rather casts the floats to > int. You can achieve the same effect with the intval function and casting. > > > echo intval(1.5); > 1 > > > echo (int) 1.5; > 1 > > Peace, > David > >