Forum Moderators: phranque

Message Too Old, No Replies

How can I make a login screen like webmasterworld's login screen?

I want to know how to do it!

         

spcoker

9:52 am on Oct 29, 2003 (gmt 0)

10+ Year Member



If anyone can explain it to me I have been given several codes that make a neat login screen but do not know how to apply them to where it will store the user names and passwords and I don't know how , after it accepts them hot to link it to the next page. If anyone can help it would be muchly appreciated.

bakedjake

4:31 pm on Oct 29, 2003 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Hi spcoker, welcome to WebmasterWorld!

There are really two types of login systems that exist for websites: server level, and program level. The one that WebmasterWorld uses is a program level login system; that is, user management and authentication is handled by the program that runs the site.

Program level systems store the usernames and passwords in some type of data store; it could be a flat text file (comma delimited or something similar), a file system database (DB3, MS Access, etc.), a typical "real" database (such as MySQL, Oracle, SQL Server, etc.), or a remote or system authentication server (/etc/passwd, LDAP, etc.).

When a program level login system receives a username and password for authentication, it verifies the login details with the authentication system, then outputs whatever you tell it to based on login acceptance or failure.

Can you be a little more specific about what you'd like to do? That way we could recommend a narrow solution for you.

spcoker

9:25 am on Oct 30, 2003 (gmt 0)

10+ Year Member



I would like to have a username and a password that could be verified on my computer. When verification is correct then it will let them go to a specific site.

The easiest way possible is a good start at least to have a better understanding of how it works!

I cant give more because I am still learning. Sorry

If you could give any help it would be appreciated very much.

Thanks Scott Coker

dougmcc1

8:44 pm on Oct 30, 2003 (gmt 0)

10+ Year Member



I think the easiest way is with a form and a script. Have a form that asks for username and password and a script with code like the following:

$username="doug";
$password="guess";

$entered_username=(whatever they enter into the form);
$entered_password=(whatever they enter into the form);

if ($entered_username == $username && $entered_password == $password) {
//go to desired site
}

Also, you could just password protect a directory, such as 'login'. So when a user types in http*//www.yoursite.com/login they get prompted for a username and password. Then create login.htm which has links to your other sites and put the page in the 'login' directory so when they login they see the links to your other sites.

RobinC

9:08 pm on Oct 30, 2003 (gmt 0)

10+ Year Member



If you look out the PHP Bible there's a whole chapter devoted to a login system, with email verification for new users and stuff like that. This one happens to do it in php (obviously) using MySQL to hold a database of users, and is pretty secure.

There are a number of ways to do it, but if you read through the chapter it explains the why's and what's for almost any good login system.

Note that there are literally hundreds of resources around, I'm mneioning this one as I've got it on the desk next to me, and rather like it's style ;-)

Robin

spcoker

12:03 am on Oct 31, 2003 (gmt 0)

10+ Year Member



dougmcc1 thanks I think I will try that. I will update you on the progress.

spcoker

12:04 am on Oct 31, 2003 (gmt 0)

10+ Year Member



RobinC thanks I will check it out.

spcoker

2:58 pm on Nov 2, 2003 (gmt 0)

10+ Year Member



bakedjake This is a reply at a later date but I have been studying the login thing for a little bit. I am a beginner but i would like to know from a - z how to make a login screen like webmaster world.coms. I am not worried about hackers as much as keeping the typical person out. My webpage is business and the members is personal. I just want them to do like the login screen in the webmasterworld to get the userid and password and if they exist then let them to the members webpage if not then return to where ever to try again or kick them either way. I want my family and friends to access the members area and not the world.

dougmcc1

2:47 pm on Nov 3, 2003 (gmt 0)

10+ Year Member



It's a form, spcoker.

<form action="scripts/script.php" method="post">
Type your username: <input type="text" name="username"><BR>
Type your password: <input type="password" name="password"><BR>
<center><input type="submit" value="Submit"></center>
</form>