Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
web_app_user_manager [2009/11/27 09:27]
Joel Dare
web_app_user_manager [2009/11/27 09:31] (current)
Joel Dare
Line 1: Line 1:
 +====== Web App User Manager ======
 +
 +This is a basic user manager for web apps.  It's a stand-alone website that verifies user information and then redirects back to the main app. This allows you to focus on web apps themselves instead of the user verification system. It's written in HTML, JavaScript, and PHP.
 +
 +\\
 +{{ usermanager.jpg }}
 +
 +===== Details =====
 +
 +The user manager is a stand alone page on the site.  Each web app checks to see if it was passed a user code.  If it was, it makes a quick API call to verify that the code is valid. ​ If the code doesn'​t exist or is not valid it simply re-directs the user to the user manager which takes care of the login process.
 +
 +===== Installing =====
 +
 +  - Extract the files into their own directory.
 +  - Manually create the database using install.mysql.
 +  - Edit the database details (4 lines) at the top of //​model.php//​.
 +  - Edit the paths (3 lines) in the //​__construct//​ function in ///​api/​user.php//​.
 +
 +===== Usage =====
 +
 +I've built the user manager so that it's very easy to use.  In each app I include only one line of code.
 +
 +  include '​../​user/​api/​user.php';​
 +
 +The user.php script will automatically verify the user value passed to the current script and re-direct the user as needed.
 +
 +===== Verify User API =====
 +
 +Normally, your web app will pass the user id (hash) code to the verify script to make sure that it's a valid id. Here's an example of passing a hash code.
 +
 +  http://​www.example.com/​user/​api/​verify.php?​h=2e870a64a151565480879ef579041d0e
 +
 +If you want to verify username and password in the web app itself you can also pass those to the verify script. ​ Here's an example of passing username and password.
 +
 +  http://​www.example.com/​user/​api/​verify.php?​u=codazoda&​p=h76EOJj76
 +
 +In either case, the script will return either the user id, on success, or the word //error// if it could not be verified.
 +
 +===== License =====
 +
 +This source code is distributed under the [[MIT License]].
 +
 +===== Files =====
 +
 +{{usermanager.zip}}
  
 

comments powered by Disqus
web_app_user_manager.txt ยท Last modified: 2009/11/27 09:31 by Joel Dare