PHP Login Help?

Reply

Join Date: Jul 2008
Posts: 1
Reputation: Rockout101 is an unknown quantity at this point 
Solved Threads: 0
Rockout101 Rockout101 is offline Offline
Newbie Poster

PHP Login Help?

 
0
  #1
Jul 6th, 2008
I have started a new website and I know basic HTML but I am clueless with PHP. I need to set up a login system where members can save their info on the site. I need to learn PHP, cookies, and a login system. Thanks.
Reply With Quote Quick reply to this message  
Join Date: May 2008
Posts: 67
Reputation: Kavitha Butchi is an unknown quantity at this point 
Solved Threads: 3
Kavitha Butchi Kavitha Butchi is offline Offline
Junior Poster in Training

Re: PHP Login Help?

 
0
  #2
Jul 6th, 2008
Originally Posted by Rockout101 View Post
I have started a new website and I know basic HTML but I am clueless with PHP. I need to set up a login system where members can save their info on the site. I need to learn PHP, cookies, and a login system. Thanks.
Hi hope this helps

http://php.about.com/od/finishedphp1...login_code.htm

they have all step by step procedures for creating a login system , setting cookies etc.
Kavitha
I Love My Indonesia.
Reply With Quote Quick reply to this message  
Join Date: Jul 2008
Posts: 1,076
Reputation: Shanti Chepuru is on a distinguished road 
Solved Threads: 98
Shanti Chepuru's Avatar
Shanti Chepuru Shanti Chepuru is offline Offline
Veteran Poster

Re: PHP Login Help?

 
0
  #3
Jul 7th, 2008
The way is:

You have to design the login page with two text boxes and then retrieve them and compare them with select statement with your database..
Then if it is ok ,navigate to another page like welcome.php...
Its very simple ,try....
Reply With Quote Quick reply to this message  
Join Date: Sep 2007
Posts: 1,540
Reputation: cwarn23 has a spectacular aura about cwarn23 has a spectacular aura about cwarn23 has a spectacular aura about 
Solved Threads: 137
cwarn23's Avatar
cwarn23 cwarn23 is offline Offline
Posting Virtuoso

Re: PHP Login Help?

 
0
  #4
Jul 7th, 2008
I have just completed a login system for a php site and although it is not open source I will tell you how it works. So for beginners, you will need to know the following:

Making sessions
http://www.tizag.com/phpT/phpsessions.php
http://au2.php.net/session_start
Making HTML Forms
The isset($_POST['variable']) command
MySQL querys
PHP Variables

And a few other small things. So to begin with, make a html page with a html login form then when it all looks perfect, change the extension to php and use the echo ""; command to show the page. Be sure not to use any double quotation marks ( " ) in your html codes otherwise you will come across problems.

After you have a html form, you have a php code at the beginning that detects if the form has been submitted. If the if function detects the form has been submited, then the script will attempt to connect to the MySQL database to check if the form details are valid. Then if the details are valid, a session is created. When the session is created, other parts of the website can see if the user is logged in. You then set the pages so that if there is no session in place, then the parts of pages (or even whole pages) will not load up.

Also if you are new to php then you should read some books and online tutorials about php before using it otherwise you may find yourself very lost. This is a brief post but I can explain more if you have any trouble understanding.
Try not to bump 10 year old threads as it can be really annoying.
http://syntax.cwarn23.net/
Smilies: ^_* +_+ v_v -_- *~*`
My favourite PC. - Oopy Doopy Do 2U2!
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:




Views: 589 | Replies: 3
Thread Tools Search this Thread



Tag cloud for PHP
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC