Thread: User Validation

    #1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2000
    Location
    LONDON
    Posts
    3
    Rep Power
    0
    Any ideas of a script that validates Users from a table in mySQL database?

    I have found one in PHP but doesn't work.


    <?php

    // File Name: auth01.php
    // Check to see if $PHP_AUTH_USER already contains info

    if (!isset($PHP_AUTH_USER)) {

    // If empty, send header causing dialog box to appear
    header('WWW-Authenticate: Basic realm="My Private Stuff"');
    header('HTTP/1.0 401 Unauthorized');
    echo 'Authorization Required.';
    exit;
    }

    // If not empty, display values for variables

    else {

    echo "
    <P>You have entered this username: $PHP_AUTH_USER<br>
    You have entered this password: $PHP_AUTH_PW<br>
    The authorization type is: $PHP_AUTH_TYPE</p>
    ";

    }

    ?>
  2. #2
  3. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Location
    Eindhoven, NL
    Posts
    22
    Rep Power
    0
    The authenticating script you displayed isn't working with mysql, but with passwordfiles.

    Just search around, I'm sure there a tons of sources out there. Or do you want me to do the searching
  4. #3
  5. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2000
    Location
    LONDON
    Posts
    3
    Rep Power
    0
    No thats ok ...

    Please let me know if you find a good working one....

    Thanks

Similar Threads

  1. Can user A read user B's session?
    By Stupid Khor in forum PHP Development
    Replies: 9
    Last Post: May 11th, 2004, 05:19 AM
  2. best way to send email validation
    By njcallen in forum PHP Development
    Replies: 2
    Last Post: January 28th, 2004, 10:02 AM
  3. php user levels
    By dynasty in forum PHP Development
    Replies: 1
    Last Post: January 20th, 2004, 02:01 PM
  4. How to get multiple sessions for one user working?
    By jkoerber in forum PHP Development
    Replies: 1
    Last Post: January 16th, 2004, 01:23 PM
  5. Is there a drop-in user control module?
    By Kent Wang in forum PHP Development
    Replies: 3
    Last Post: December 20th, 2003, 05:20 AM

IMN logo majestic logo threadwatch logo seochat tools logo