From fa4771c80ea76ce8a551a2f9194508713f02715f Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 18 Mar 2005 22:27:03 +0000 Subject: [PATCH] =?UTF-8?q?Fix:=20Correction=20mauvaise=20utilisation=20de?= =?UTF-8?q?=20la=20methode=20fectch=5Fobject=20avec=20en=20param=E8tre=20u?= =?UTF-8?q?n=20indice=20au=20lieu=20d'un=20resultset.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/product/liste.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/htdocs/product/liste.php b/htdocs/product/liste.php index cee01ab2930..8890406f81e 100644 --- a/htdocs/product/liste.php +++ b/htdocs/product/liste.php @@ -117,13 +117,13 @@ $result = $db->query($sql) ; if ($result) { - $num = $db->num_rows(); + $num = $db->num_rows($result); $i = 0; if ($num == 1 && (isset($_POST["sall"]) or $snom or $sref)) { - $objp = $db->fetch_object($i); + $objp = $db->fetch_object($result); Header("Location: fiche.php?id=$objp->rowid"); } @@ -197,7 +197,7 @@ if ($result) $var=True; while ($i < min($num,$limit)) { - $objp = $db->fetch_object( $i); + $objp = $db->fetch_object($result); $var=!$var; print ""; print "rowid\">"; @@ -210,7 +210,7 @@ if ($result) print "\n"; $i++; } - $db->free(); + $db->free($result); print "";