I was beginning to think no one was going to reply.
I store all of my data in cookies so that I do not have to retrieve the
same data over and over as you stated.
For example, on one of my sites users can only hit the pages that they have
paid for. So, when they login the first thing I do is set a cookie that
lists all of the pages that they can hit.
I also store what layout the user has selected as well as any color
variables I need. But once I store them I do not hit the database again
unless they make a change to their preferences.
So what you are saying is that you are passing these session variables
through the url on every page request? And that you find this much more
effective then storing this data in cookies?
kaigler
At 10:01 AM 3/23/2001 -0800, you wrote:
> > I have never switched to passing these variables through the url because I
> > have always had something more critical to do.
> >
> > So, the topic for the day and we can carry this to next week is:
> >
> > How do you handle cookies/session variables?
>
>
> That's a pretty broad subject. I normally don't use that many
>cookie variables. I use cookies just as a method for restoring
>state/identification of the user so they don't need to log in again, ie
>some kind of SessionKey. So that if the user comes back, and their Session
>vars are gone, I check the SessionKey and the Username in the database and
>if they match I can automatically restore their state (via Session
>vars). If the sessionkey has expired, and the session vars are still valid
>then the sessionkey is updated. Otherwise they have to log in again to
>have access to the extra stuff.
>
> Session vars are more convenient and faster to use. As well they
>can store more complex data types, unlike cookies. CPU power is cheap. RAM
>is cheap. Making database queries is not cheap, you take a huge relative
>performance hit everytime you do that. So if you were only using cookie
>vars then things you would have to keep retrieving from the database,
>you'd have to keep doing over and over again if your objects needed the
>same complex information.
>
>
>
> Tariq Ahmed - [EMAIL PROTECTED] - ICQ H:6308515/W:43686521
> TIBCO Finance Technology - Web Group - Senior Web Engineer
> Work: 650-461-3472 Cell: 650-799-6636 Fax: 650-461-3003
> 3375 Hillview Avenue. Palo Alto, CA. 94304.
>
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
------------------------------------------------------------------------------
To unsubscribe, send a message to [EMAIL PROTECTED] with
'unsubscribe' in the body or visit the list page at www.houseoffusion.com