![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Expert Programmer
|
Log in help
How can i have a login in screen on my web page for different users. I need it so that I can put things on my site that can only be accessed by people who have logged in.
P.S. I am not very good at understanding complicated things so try to make it kind of simple. |
|
|
|
|
|
#2 |
|
I eat cake for breakfast.
![]() ![]() ![]() ![]() Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9
![]() |
Well, let's start off with this: you know PHP, right?
|
|
|
|
|
|
#3 |
|
Expert Programmer
|
I know of it.
|
|
|
|
|
|
#4 |
|
Programming Guru
![]() |
well i would first look up a web scripting language such as php learn it and as you learn it you will find out how to make the login page.
__________________
"Put your hand on a hot stove for a minute, and it seems like an hour. Sit with a pretty girl for an hour, and it seems like a minute. THAT'S relativity." - Albert Einstein |
|
|
|
|
|
#5 |
|
Programmer
Join Date: Jun 2005
Location: Queensland
Posts: 37
Rep Power: 0
![]() |
learn php
you could either put the username and password on the page itself, but that isnt secure at all but easy, or you could link it to a database. you have to make watever is typed into the user and pass txt boxes equal variables such as $user or $pass respectively. no DB means you could say
if ($user == john, $pass == smith) { //code that redirects to the members area } that is the easiest way of making a 'login' of sorts. but i think you should learn some php because if you dont know the basics you are screwed even doing it the easy way. |
|
|
|
|
|
#6 | |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
What language is this ???
Quote:
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers |
|
|
|
|
|
|
#7 |
|
Hobbyist Programmer
Join Date: Sep 2004
Posts: 207
Rep Power: 4
![]() |
Yeah it would be
if($user == "john" && $pass == "smith") { //Your commands here } In php
__________________
_______________________________ BlazingWolf |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|