1.
<?
$row = mysql_fetch_row($result);
?>
Returns a regular array, $row, $row[0] is the first element,
$row[1] is the second element, ...
mysql_num_fields($result) returns the number of fields in
the result.
2.
<?
$row = mysql_fetch_array($result);
?>
Returns an array that contains all of the above elements,
but in addition, it contains associative indices too.
For example, if the result is
username | password
-------------------------------------
bourbon | abc
berber | efg
Then when you do :
<?
$row = mysql_fetch_array($result)
?>
for the first time:
<?
$row[0] = $row["username"] = "bourbon"
$row[1] = $row["password"] = "abc"
//The second time:
$row[0] = $row["username"] = "berber"
$row[1] = $row["password"] = "efg"
?>
(it doesn`t matter how the result was generated,
i.e. by select * or by select username,password).
3.
<?
$row = mysql_fetch_object($result);
?>
Returns an object that describes the row. In the above
example, the first time you`d call it:
<?
$row->username = "bourbon"
$row->password = "abc"
//The second time:
$row->username = "berber"
$row->password = "efg"
?>
bookmarker - PHP, PHPLIB, MySQL WWW based bookmark manager Categories : MySQL , PHP , MySQL , Complete Programs , Databases This program allows you to upload an ODBC ressource - i.e. an MS-Access database to a MySQL server. Categories : Databases , MySQL , Complete Programs , PHP , Databases Identify and log search engine access (spiders, robots, etc.) to a page. Categories : HTTP , Environment Variables , PHP , MySQL , Databases Visits-tracking Categories : PHP , Databases , MySQL , Errors and Logging , Functions A simple script to count and report hits and the last
modification time of an HTML page. Requires MySQL support
(other DBs should work too, except possibly mSQL). Categories : HTTP , MySQL , PHP , Databases Finds the median in an array of numbers - Can be used with a MySql database column read into an array Categories : PHP , Arrays , Databases , MySQL Password reminder Categories : PHP , PHP Classes , Databases , MySQL , Mail dynamic table columns Categories : PHP , HTML and PHP , Arrays , Databases , MySQL Pull Down Surfing - Surf on Change Categories : Java Script , MySQL , HTML and PHP , PHP , Databases Online Automatic Class Generator for MySQL Tables Categories : PHP , PHP Classes , Classes and Objects , Databases , MySQL create a grid out of <INPUT TYPE=TEXT> then saving to a database. Uses
a 'multi-dimension array', but not really as the array is just one big array
with the index of "[$i][$j]". Have a look at the code and you'll see what I
mean. Categories : PHP , MySQL , Arrays , Databases Specify your connection settings and create a link to a MySQL database. Categories : PHP , PHP Classes , Databases , MySQL , Beginner Guides Paginator - a class that can help you to split MySQL database query result sets to pages. Categories : MySQL , Databases , HTML , PHP Warning: Unknown(): A session is active. You cannot change the session module's ini settings at this time. in Unknown on line 0 Categories : PHP , Sessions , Databases , MySQL A template script to provide the ability to get the next or previous n records from a MySQL database. Categories : Databases , PHP , MySQL