www.webdeveloper.com
Results 1 to 2 of 2

Thread: need help with session varibles

  1. #1
    Join Date
    May 2003
    Posts
    8

    need help with session varibles

    I need a little help with session variables.

    Okay, say I have index.php
    In this index, I have a login form.
    The client enters their username and password, and login.php page verifys the data, by comparing with a mysql table
    If correct, login.php will create a session variable, and forward the client to home.php
    home.php will automatically check if the user is logged in, and, if they are, show the data, else forward back to login.php

    I need to know how to make login.php make the session varible and how to make home.php check to see if the user is logged in (using the session variable)

    Finally, the data on home.php depends on the username, so I need to know how to carry-over the username, within the session variable

    Thanks a bunch!

  2. #2
    Join Date
    Feb 2003
    Location
    Britain
    Posts
    1,335
    Are you wanting to use cookies, specially formatted URLs (e.g. acccessibity stuff at http://members.lycos.co.uk/index1.php
    or IP and info logging with a back end database (not recommended). The easiest to use is cookies, the most accessible is special URLs.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles