From 5bb1f07bbfa5ccfa675a2bbc2b48bb56dfe8ea07 Mon Sep 17 00:00:00 2001 From: Kenneth Schwartz Date: Sun, 9 Jan 2005 16:43:25 +0000 Subject: [PATCH] Fix proto, update example incorporating notes git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@176735 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/pgsql/functions/pg-fetch-row.xml | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/reference/pgsql/functions/pg-fetch-row.xml b/reference/pgsql/functions/pg-fetch-row.xml index 0709f5d467..0f99c08226 100644 --- a/reference/pgsql/functions/pg-fetch-row.xml +++ b/reference/pgsql/functions/pg-fetch-row.xml @@ -1,5 +1,5 @@ - + @@ -11,7 +11,7 @@ arraypg_fetch_row resourceresult - introw + introw pg_fetch_row fetches one row of data from @@ -30,26 +30,23 @@ <function>pg_fetch_row</function> example \n"; - +while ($row = pg_fetch_row($result)) { + echo "Author: $row[0] E-mail: $row[1]"; + echo "
\n"; } ?> @@ -61,7 +58,7 @@ while ($row = pg_fetch_row($result, $i)) { From 4.1.0, row became optional. Calling pg_fetch_row will increment - internal row counter by 1. + the internal row counter by one.