On Tuesday 03 February 2004 01:09, Christopher J. Crane wrote:
> Well this is it and it is really got me...
> Echoing out the $Symbol and $Price works just fine one row about the
> $TickerData array assignment. Yet it outputs nothing.
> "Array ( [] => )" is what I get. If I change the line to
> $TickerData = array ("$Symbol" => "$Price"); I get nothing, or the same
> result. If I change the line to
> $TickerData = array ('$Symbo'l => '$Price'); I get the following
> Array ( [$Symbol] => $Price ) which tells me the assignment works, but it
> seems like the $Symbol and $Price variable are blank when assigning to the
> array. I know that they are not blank since they echoed out just fine one
> line above.....<GRRRRRR>

Are you sure that the line: echo $Symbol ...
is displaying something sensible for each $Row?

You're overwriting $TickerData at each iteration of the foreach-loop thus if 
your last $Row doesn't contain something sensible neither would $TickerData.

You probably want to use this assignment instead:

  $TickerData[$Symbol] = $Price;

-- 
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
------------------------------------------
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
------------------------------------------
/*
TANSTAAFL
*/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to