Session Varaibles or constants ??

Results 1 to 2 of 2

Thread: Session Varaibles or constants ??

  1. #1
    Paul M Guest

    Default Session Varaibles or constants ??

    I am at the moment using a session variable to store a users access to my website, and also to provide security from people skipping the login stage, and accessing data below that. The question that I have is that my userbase is likely to increase quite alot over the next couple of weeks, and I was reading that using a constant instead of a session variable saves on server resources ??<BR><BR>If so, by how much, and how do I change from using session variable to constants ??<BR><BR>Any help or links to articles would be great.<BR><BR>Thanks<BR>Paul M

  2. #2
    Join Date
    Dec 1969

    Default RE: Session Varaibles or constants ??

    Remember that a session variable starts when it is defined and ends when the user ends their session by leaving your site or quitting the browser. Therefore, you will only have a session variable open for each simultaneous user - i.e. if you had 10,000 accesses in a week, but only 100 at any given time, you probably don&#039t have any great server resource issues because you only have 100 session variables open. Alternatives might include having a user database which you can then use to store longer term info, such as when the user last visted, their preferences and habbits.<BR><BR>Just a thought.<BR><BR>DC

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts