PHP Classes

twzAuth: Authenticate users using HTTP Basic authentication

Recommend this page to a friend!
  Info   View files Example   View files View files (9)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 303 All time: 7,380 This week: 175Up
Version License PHP version Categories
twzauth 0.1.1GNU General Publi...5PHP 5, Files and Folders, User Manage..., S...
Description 

Author

This class can authenticate users using HTTP Basic authentication.

It can add users to authorize with given user name and password and stores the user list in a file.

The class can load the users list from the file and validate if the user authenticated with the HTTP Basic authorization prompt has entered the correct password.

It can also edit and delete users stored in the users list file. The file may also include information of whether the user has administrator status and other custom user properties.

Picture of Tony
Name: Tony <contact>
Classes: 6 packages by
Country: United States United States
Age: ???
All time rank: 990138 in United States United States
Week rank: 312 Up38 in United States United States Up
Innovation award
Innovation award
Nominee: 2x

Example

<?php
/*
    twzAuth-include.php (simple mode)

    If you only have one page to protect, these commands can be in that script.
    We've used this include file to make it easier to protect multiple pages.

*/

$ValidUsers=array('user_1'=>'wr$5trTygY67I86', 'user_2'=>'deFgt%4ddChg7*6');

require
'../twzAuth.class.php';
$auth=new twzAuth($ValidUsers);

$Username = $auth->validate();


?>


  Files folder image Files  
File Role Description
Files folder imageexamples (6 files)
Plain text file twzAuth.class.php Class twzAuth class
Accessible without login Plain text file twzAuth.doc.txt Doc. Documentation
Accessible without login Plain text file GPL.txt Lic. License

  Files folder image Files  /  examples  
File Role Description
  Accessible without login HTML file index.html Data examples entry page
  Accessible without login Plain text file extended-admin.php Example example script
  Accessible without login Plain text file extended-example.php Example example script
  Accessible without login Plain text file extended-include.php Example example script
  Accessible without login Plain text file simple-example.php Example example script
  Accessible without login Plain text file simple-include.php Example example script

 Version Control Unique User Downloads Download Rankings  
 0%
Total:303
This week:0
All time:7,380
This week:175Up