Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    CSS
    CSS is offline
    New Coder
    Join Date
    Jun 2006
    Posts
    40
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Password Protected 'Login' for Comments

    I'm making a website for a group of friends of mine in PHP that is going to password protected and given out to about 5 people. Logging into the site will basically identify who's been to the site, as each of the 5 will be given a different password. After logging in, they will just be directed to a page with a "Comments" field, and then comments left by other people displayed above it.

    As the enter their comment and post it, their 'name' will automatically be determined by what password they login with. For example:

    Jdh7GA5 - Frank's password to login to the website
    Kz08Nba - Dan's password to login to the website

    If someone logs in with the password Jdh7GA5 and submits a comment, the comment is displayed as "Frank: (his comment here)"

    I'm having trouble constructing this myself.

  • #2
    Senior Coder
    Join Date
    Jan 2007
    Posts
    1,648
    Thanks
    1
    Thanked 58 Times in 54 Posts
    Alright. What have you done so far, and what are you not sure of?

  • #3
    UE Antagonizer Fumigator's Avatar
    Join Date
    Dec 2005
    Location
    Utah, USA, Northwestern hemisphere, Earth, Solar System, Milky Way Galaxy, Alpha Quadrant
    Posts
    7,691
    Thanks
    42
    Thanked 637 Times in 625 Posts
    The easiest way to do this would probably be via HTTP request authentication. Google HTTP authentication for more info.

  • #4
    Registered User
    Join Date
    Oct 2007
    Posts
    55
    Thanks
    4
    Thanked 2 Times in 2 Posts
    which part do you need help with? the comments part, or the password part? i'm definitely not the most experienced programmer here, but i could easily show you a way to determine the user's name by their password with the comments. (please note my way will require a database.)

  • #5
    CSS
    CSS is offline
    New Coder
    Join Date
    Jun 2006
    Posts
    40
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by ConnorMHB View Post
    which part do you need help with? the comments part, or the password part? i'm definitely not the most experienced programmer here, but i could easily show you a way to determine the user's name by their password with the comments. (please note my way will require a database.)
    I need help with the password part, storing the person's name effectively as they enter their password for it to be displayed as they enter a comment. I'm not good at all with SQL, and I was wanting to store everything in a database, really... the passwords/names, as well as a list of comments, ordered by time posted and by whom.


  •  

    Posting Permissions

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