Re: Array problrem!

From: Date: Wed, 14 Nov 2001 09:35:23 +0000
Subject: Re: Array problrem!
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-74568@lists.php.net to get a copy of this message
It seems you data are down-taken to Integers (int) instead of the correct variable type. Try to define the array as an array of correct types, otherwise the array will be "int type" and will contain integers (1.2 taken to 1, 0,5 taken to 0, and so on) J "De Necker Henri" <deNeckerH@ford.co.za> ha scritto nel messaggio news:3A8ED7A62794D311AA7700508B6164EC08DCA38A@SCPTS01... > Hi there. > I have an array like this : 1.2 , 0.3 , 0.5 , 1.6 , 0.3 > I output like this: > > while($data_array[$j]){ > echo "<br>$data[$j]" ; > $j++ ; > } > > My output is like this : 1 , 0 , 0 , 1 , 0 > The values in the db are floats and are read correctly ! > > Why is the values not there.Is there a specific way to store values in a > array?

« previous php.general (#74568) next »