note 75108 added to function.mysql-fetch-assoc

From: Date: Sat, 12 May 2007 20:37:25 +0000
Subject: note 75108 added to function.mysql-fetch-assoc
Groups: php.notes 
Request: Send a blank email to php-notes+get-126466@lists.php.net to get a copy of this message
Correction to function mysql_fetch_assoc_improved below: <?php if (isset($first_fields[$field->name])) { //this is not the first field with this name ?> must be <?php if (array_key_exists($field->name, $first_fields)) { //this is not the first field with this name ?> because isset() will return FALSE if testing a variable that has been set to NULL... ---- Server IP: 194.109.193.76 Probable Submitter: 82.172.208.34 ---- Manual Page -- http://www.php.net/manual/en/function.mysql-fetch-assoc.php Edit -- https://master.php.net/note/edit/75108 Del: integrated -- https://master.php.net/note/delete/75108/integrated Del: useless -- https://master.php.net/note/delete/75108/useless Del: bad code -- https://master.php.net/note/delete/75108/bad+code Del: spam -- https://master.php.net/note/delete/75108/spam Del: non-english -- https://master.php.net/note/delete/75108/non-english Del: in docs -- https://master.php.net/note/delete/75108/in+docs Del: other reasons-- https://master.php.net/note/delete/75108 Reject -- https://master.php.net/note/reject/75108 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#126466) next »