SitePoint Sponsor

User Tag List

Results 1 to 3 of 3

Thread: Secure Login

  1. #1
    SitePoint Member
    Join Date
    Aug 2010
    Posts
    18
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Secure Login

    Hello Again!

    I hope you guys can help me out here. I'm still working on my clients site, it's uploaded and hosted now at <snip />, and they are in need of a secure login form. But I'm kind of stumped with it, I created a nice "twitter style" form for the client but I can't seem to "use" it.

    I'm using wordpress as a CMS if that helps.

    Are there any tutorials you could point me to?

    I'm pretty decent, but still a newbie, with PHP, I managed to create a file uploader (which is why I we are in need of the secure login). I know I need a 'users' database in the phpadmin area, but after that, i'm stumped on how to code it.

    Thanks in advance!
    Last edited by DaveMaxwell; Sep 20, 2010 at 07:08.

  2. #2
    Non-Member Kalon's Avatar
    Join Date
    Aug 2010
    Location
    At my computer
    Posts
    2,012
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Here is some demo login code I just googled to get you started.

    It uses some deprecated php code: session_register.

    You should use $_SESSION['username'] instead.

    Also, don't forget to sanitise all user inputs from forms using mysql_real_escape_string() otherwise your login code will be vulnerable to sql injection attacks.

  3. #3
    Just Blow It bronze trophy
    DaveMaxwell's Avatar
    Join Date
    Nov 1999
    Location
    Mechanicsburg, PA
    Posts
    7,254
    Mentioned
    113 Post(s)
    Tagged
    1 Thread(s)
    FYI - OP reported that he resolved the problem, so I'm going to go ahead and close the thread...
    Dave Maxwell - Manage Your Site Team Leader
    My favorite YouTube Video! | Star Wars, Dr Suess Style


Bookmarks

Posting Permissions

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