RE: [PHP-DB] Previous | Next (Again)

From: Date: Fri, 31 Aug 2001 19:04:59 +0000
Subject: RE: [PHP-DB] Previous | Next (Again)
Groups: php.db 
Request: Send a blank email to php-db+get-12052@lists.php.net to get a copy of this message
Hello!!! Now that I have found a better link to understand and use the code for next/previous...here it is... http://www.onlamp.com/pub/a/php/2000/11/02/next_previous.html I use this idea with every database..... This also teaches you...mysql_fetch_object PhPBuilder is "OK" but this one better to understand....Plus it's a lot cleaner.... I think this is the best around... Dan > ---------- > From: Jeff Oien > Reply To: jeff@webdesigns1.com > Sent: Thursday, August 30, 2001 8:18 PM > To: PHP-DB > Subject: [PHP-DB] Previous | Next (Again) > > I'm having a hard time figuring this out. I have a photo album that > displays > one image at a time. I want to have Previous and Next links for images > in > a users album. This was suggested: > http://www.phpbuilder.com/columns/rod20000221.php3 > but it seems to be more for a number of results instead of one. > > At first I used the id field which is auto_increment and did -1 for > previous +1 for next but then realized if they delete an image in > the album the id field is no longer successive by 1. I can count > the number of images in an album but not sure how to know which > is the first, which is the second etc. and know which the current > one is if the id field has gaps in it. Not sure if that made any > sense. > Jeff Oien > > -- > PHP Database Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net > For additional commands, e-mail: php-db-help@lists.php.net > To contact the list administrators, e-mail: > php-list-admin@lists.php.net > >

« previous php.db (#12052) next »