You are resetting $row inside your loop. Don't do that.
On Sun, 19 May 2002, Lee P Reilly wrote:
> Hi,
>
> I wonder if someone could have a quick look at this for me? It's a
> simple while loop, but it's not acting the way (I think) it should. If I
> break down the while loop, it reads:
>
> ---
> while($row = mysql_fetch_array($result))
> {
So, your while loop is based on values of $row.
> $row = mysql_fetch_array($result);
Now within your while loop you've altered the value of $row - poor thing
is probably a tad confused.
CYA, Dave
--
PHP General Mailing List (http:/
uot;Y")
23 $html .= "$concentration $concunit $compname";
24else if ($pri=="Y")
25 $html .= " $concentration $concunit
$compname";
26else
27 $html .= " $concentration $concunit $compname";
28 }
-Original Message-
From: Lee P
LPR>
LPR> while($row = mysql_fetch_array($result))
LPR> {
LPR> $pri = $row['pri'];
LPR> $fg = $row['fg'];
LPR> $molw = $row['molw'];
LPR> $density = $row['density'];
LPR> $denstype = $row['denstype'];
LPR> $pctd = $row['pctd
Hi,
I wonder if someone could have a quick look at this for me? It's a
simple while loop, but it's not acting the way (I think) it should. If I
break down the while loop, it reads:
// $result contains 3 rows
while($row = mysql_fetch_array($result)
5 matches
Mail list logo