Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
Need code for login page????
Old 05-25-2006, 09:28 AM Need code for login page????
Novice Talker

Posts: 5
Trades: 0
Can someone help me out with getting a code to create for my employees to login an access page
joeywebber is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 05-25-2006, 05:52 PM Re: Need code for login page????
cdwhalley.com's Avatar
Skilled Talker

Posts: 75
Trades: 0
A good tutorial I found, that's actually quite different, is: http://www.zend.com/zend/tut/authentication.php
cdwhalley.com is offline
Reply With Quote
View Public Profile Visit cdwhalley.com's homepage!
 
Old 05-26-2006, 12:17 PM Re: Need code for login page????
Experienced Talker

Posts: 31
Trades: 0
I use this:

PHP Code:
require('../password.php');
if ($logins[$_POST['user']] == $_POST['pass']
&& $_POST['user'] != ""
&& $_POST['pass'] != ""){
?>
YOUR CONTENT HERE
<?php
}
else{
?>
<center>
<form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="POST">
<table width="313" border="0">
    <tr>
      <td width="75"><p align="right">Username:</p>
        <p align="right">Password:</p></td>
      <td width="228"><p>
        <input type="text" name="user" />
      </p>
        <p>
          <input type="password" name="pass" />    
            </p></td>
    </tr>
  </table>
<input type="submit" value="Login" />
</form>
</center>
<?php

}

?>
where password.php is..

PHP Code:
$logins = array (
"admin" => "password"
"username" =>"password"
"user2" =>"pass2"
); 
enerbrat is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Need code for login page????
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.27083 seconds with 12 queries