|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
PHP & MySQL: Basics Tutorial by Ben Rowe
Hi,
I am new to this and I dont know much of PHP Coding. I took the PHP and mySQL Bascis tuts by Ben found on this page. The tut is extremely simple to understand and apply. Thumbs up to it. The tutorial says has an address book. Now all I want to do is, only display the very latest address and not the old ones. I would like to know how I do that? I tried different ways but all in vain. Please help me out with this. Any help provided will be highly appreciated. Please answer me keeping in mind that I dont have knowledge about PHP coding. Thank you ![]() |
|
#2
|
|||
|
|||
|
whoa, its a been a while since ive done been though this article
![]() MySQL by defaults orders the rows by the way you enter them into the database. So in order to get the last entry you could use the following query SELECT * FROM address ORDER BY id DESC LIMIT 1 This would return the last entry of the table. You could then use the mysql_fetch_array function to retrieve those results, and get the data array. |
|
#3
|
|||
|
|||
|
Thnx alot Ben
This really worked out for me *Cheers* ![]() Last edited by dbdesigns : April 26th, 2003 at 04:14 AM. |
![]() |
| Viewing: Dev Articles Community Forums > Databases > MySQL Development > PHP & MySQL: Basics Tutorial by Ben Rowe |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|