PHP Classes

SMK User Authentication: Authenticate users with MySQL database records

Recommend this page to a friend!
  Info   View files View files (8)   DownloadInstall with Composer Download .zip   Reputation   Support forum (2)   Blog    
Ratings Unique User Downloads Download Rankings
StarStarStarStar 61%Total: 2,751 All time: 1,375 This week: 555Up
Version License Categories
smk_auth 1.0GNU General Publi...Databases, User Management
Description 

Author

This package can be used to authenticate users against a MySQL database of user records.

It can verify whether there is a record for an active user given the user name and password.

If the authentication succeeds, it creates a record for a new session in another database table.

The new session identifier is set to a session cookie. This cookie can be verified in subsequent accesses to determine whether the user was previously authenticated and the session did not expire.

Picture of Andrei
Name: Andrei <contact>
Classes: 1 package by
Country: Romania Romania
Age: 49
All time rank: 115628 in Romania Romania
Week rank: 4277 Down76 in Romania Romania Down

Details

Fist of all, this package is based on the authentication used in mambo/joomla, also including the database object of this premium CMS (www.joomla.org) . The files are altered to ensure stand-alone functioning of the classes. Mostly i worked on auth.class.php, in database.php i just got out some code that dd not make sense outside the joomla framework Installing ============= 1. Import the "script.sql" in your MySQL Database (It adds a default user "Testman", password "t") 2. Alter the db.inc.php accourding to your system setup. Please adjust the SESSION timeout since it is maybe to high for you. 3. Build a login page similar to my example "login.php". you should include the two files require_once('auth.class.php'); require_once('db.inc.php'); 4. in all the "registered only" pages include "require_once('auth.php')" on top. Please check "index.php" Please write me if you find some bugs or problems Enjoy Andrei gringo696@yahoo.com

  Files folder image Files  
File Role Description
Plain text file auth.class.php Class Core Authentication class
Accessible without login Plain text file auth.php Aux. Authentication module
Plain text file database.php Class Database Class (a light version of the one included in the joomla distribution)
Accessible without login Plain text file db.inc.php Conf. Configuration script. Adjust to your Mysql configuration
Accessible without login Plain text file index.php Example Example file that uses authentication
Accessible without login Plain text file login.php Example Example login script.
Accessible without login Plain text file Readme.txt Doc. Documentation, how-to-install
Accessible without login Plain text file script.sql Data Table creation script

 Version Control Unique User Downloads Download Rankings  
 0%
Total:2,751
This week:0
All time:1,375
This week:555Up
User Ratings User Comments (1)
 All time
Utility:75%StarStarStarStar
Consistency:87%StarStarStarStarStar
Documentation:70%StarStarStarStar
Examples:79%StarStarStarStar
Tests:-
Videos:-
Overall:61%StarStarStarStar
Rank:1070
 
Very useful authentication class.
16 years ago (Alex Capalneanu)
75%StarStarStarStar