Re: Create unike variables for each record

From: Date: Fri, 17 Jan 2003 03:58:56 +0000
Subject: Re: Create unike variables for each record
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-131964@lists.php.net to get a copy of this message
Is it possible to register an array as a session variable? If so I think it solves my problem. Thanks. Lars "Lars Espelid" <lars_espelid@hotmail.com> skrev i melding news:20030117031747.51894.qmail@pb1.pair.com... > Hello, > > I have a table in a MySQL-db. The primary-key-coloumn is a number which is > not sorted. I don't know how many records there are. > > I have a while-loop in a php-page which prints a link for each record. Each > link points to the same page (iow. page reloads). > > When someone click on one of these links I would like to create a unike > session-variable which identifies the links record and set it's value like > 1. The next time someone click on the link, the variable should be set like > 0. > > The meaning is to run another query if a record's variable is set to 1 and > display it. The page will then have functionality like windows explorer (you > can click on a folder and it will then display its contents). > > The problem is how I can make a unike variable for each record and know how > to call it(know it's name). > > Hope someone understands my problem. (difficult to explain) > > Thanks. > > Lars > >

« previous php.general (#131964) next »