Re: variable types

From: Date: Thu, 08 Jun 2000 15:23:13 +0000
Subject: Re: variable types
References: 1  Groups: php.windows php.windows php.windows 
Request: Send a blank email to php-windows+get-349@lists.php.net to get a copy of this message
Mikkel Erup wrote: > > Hi. I use php4 on Windows 2000. I have the following problem, which I hope someone can help me > about. > > I use the following: > > <? > $a = 1.2; > echo $a; > ?> > > it states 1 ??? > > whats the problem. Why doesnt it state 1.2? echo gettype($a); states double, so the type should > be right. Using $a = 1.2e3 or $a = (double) 1.2 gives me the same result. whenever I use doubles in > expressions like $c = ($a * $b); where $a and $b are doubles it seems to be using integer values, > even if I use the cast operator (double). > > -- > Mikkel Erup > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-windows-unsubscribe@lists.php.net > For additional commands, e-mail: php-windows-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net see setlocale () function in String Functions chapter of php manual. -- Stas Trefilov Moscow Russia

« previous php.windows (#349) next »