Top

Login System


PHP Code
+ 0 likes
Please Register to submit score.
Average Score  5.0
Scores Submitted  1
Date Added  Dec 30, 2006
Last Updated  Dec 30, 2006
Tags  login  mysql  register  system 
  Bookmark and Share

Introduction

«Description»

This is a login System, it has 3 files
login.php
register.php
lastmember.php

once a user has been logged in it will return him/her to the home page. to see if they are logged in use the code at the bottom of my script

When a user registers, it will update the lastmember.php page, so you can include it in your home page by using <? include('lastmember.php'); ?> and it shows the last member that signed up. you can add/change the stuff in the last member.php page but i suggest not changing anything, because i hate people saying they changed so and so and it doesn't work. so just leave it alone :P

Enjoy

Grab the Code

Comments

  (20)  RSS
F*U*R*B*Y*
Comments: 585
 
PHP Snippet:  Login System
Posted on Dec 30, 2006 10:41 pm
wo0t go my complex login system :P
Hawkee
Comments: 566
 
PHP Snippet:  Login System
Posted on Dec 31, 2006 1:58 am
You should include the SQL create statement for your table. Check my review system snippet to see what I mean. Also, why not put the dbhost, dbusername, etc. connection parameters in one place. You can do this entire thing in a single document with a switch statement or some if-statements.
F*U*R*B*Y*
Comments: 585
 
PHP Snippet:  Login System
Posted on Dec 31, 2006 3:26 am
i thought i uploaded it :P i'll find it and update this script
Noutrious
Comments: 355
 
PHP Snippet:  Login System
Posted on Dec 31, 2006 5:45 am
It would be perfect, if it included PM system, Personal info setter etc.
F*U*R*B*Y*
Comments: 585
 
PHP Snippet:  Login System
Posted on Dec 31, 2006 6:16 am
yeah i'm writing a PM system now :P
Noutrious
Comments: 355
 
PHP Snippet:  Login System
Posted on Dec 31, 2006 7:20 am
Nice :)
sean
Comments: 108
 
PHP Snippet:  Login System
Posted on Dec 31, 2006 9:41 pm
Hawkee, when are you making a system to allow multiple *.php file uploads? not being pushy, just curious.
Hawkee
Comments: 566
 
PHP Snippet:  Login System
Posted on Dec 31, 2006 11:09 pm
sean, that idea has been on the backburner for some time. Still need to flesh it out and find the time to work on it.
F*U*R*B*Y*
Comments: 585
 
PHP Snippet:  Login System
Posted on Jan 17, 2007 6:12 pm
PM System is completed, if Hawkee does do the multiple *.php file uploads i'll upload it with my login system... if you want it before hand i'll post it as a snippet
cooolstar
Comments: 12
 
PHP Snippet:  Login System
Posted on Jan 25, 2007 4:07 pm
salamz,
Furby gave users a very good script.
but it was good if he would paste here without any <table tags>.

but it is good, any one having any problems with other login systems can get idea of logins by his snippet very quickly.

nice one :)
Bandit
Comments: 7
 
PHP Snippet:  Login System
Posted on Feb 17, 2007 6:22 pm
Nice code, I'd just like to point out one thing though. Your code is vulnerable to SQL injection, and these kind of attacks are becoming more and more popular. Try using the mysql_real_escape_string function. It helps protect against such attacks.

--Bandit
F*U*R*B*Y*
Comments: 585
 
PHP Snippet:  Login System
Posted on Feb 18, 2007 5:48 am
Can you please explain more, i really don't get in to the SQL Injections, i stay clear of that, so can you explain it and tell me what i have to change, so i can add it :)
Hawkee
Comments: 566
 
PHP Snippet:  Login System
Posted on Feb 19, 2007 1:26 pm
Here is a perfect example:

http://en.wikipedia.org/wiki/SQL_injection
log2
Comments: 52
 
PHP Snippet:  Login System
Posted on Feb 9, 2008 5:28 pm
You shouldn't recall your database at the top of the page, it should be hidden, and in an htaccess directory so people can't see your information (There are ways of downloading PHP files)
AdrianF
Comments: 37
 
PHP Snippet:  Login System
Posted on Jun 6, 2008 8:40 am
How I Upload THis? And Configure and shoot?
F*U*R*B*Y*
Comments: 585
 
PHP Snippet:  Login System
Posted on Jun 6, 2008 9:02 am
You place the files in seperate files, then save them as what i said to. and then upload to your webhost
AdrianF
Comments: 37
 
PHP Snippet:  Login System
Posted on Jun 6, 2008 10:38 am
how?
AdrianF
Comments: 37
 
PHP Snippet:  Login System
Posted on Jun 6, 2008 10:38 am
fark i'm can be not smart at some shoot
jonesy44
Comments: 1,085
 
PHP Snippet:  Login System
Posted on Jun 6, 2008 2:16 pm
make new files on your host;

login.php
register.php

and copy the relevent parts of the files into the files.

This then uses cookies/sessions, (i haven't read it fully) to tell whether a user is logged in/not
Nalemin
Comments: 2
 
PHP Snippet:  Login System
Posted on Aug 24, 2008 2:37 pm
Umm, so what's the query I would use to make the table for it? :(

Also, I'm getting this error:

Parse error: parse error, unexpected T_ECHO in /home/www/aurora-online.org/register.php on line 34

Please Register or Login to start posting comments.
Bottom