News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Adam Jensen's Blog:
Flexible User Authentication with Zend_Auth
April 10, 2009 @ 07:56:35

Adam Jensen has written up a new article today on how you can use the Zend_Auth component of the Zend Framework to authenticate your users in a few different ways based on a strategy selected.

For this example, we're going to allow our users to authenticate in one of multiple ways: e.g., against a database table, against an LDAP server, or by OpenID [1]. Zend_Auth already provides the necessary authentication adapters, so what we'll be concerned with here is how to implement all three systems without ending up in an FSUC situation.

He defines the code for the basic controller and a simple view that allows the user to select how they want to log in - email/password, username/password or OpenID. The model does all of the heavy lifting by letting the controller set the authentication type (strategy) and pulling in the correct Zend_Form instance along with its validation rules. Code is also included for the model and each of these.

2 comments voice your opinion now!
flexible user authentication zendauth zendframework email password username openid


blog comments powered by Disqus

Similar Posts

Tibo Beijen's Blog: Using Zend_Form without Zend Framework MVC

Matthew Weier O'Phinney's Blog: Zend Framework 1.6.0 Preview, or, PHP 4 is Dead

Matthew Weir O'Phinney's Blog: Zend Framework MVC Webinar posted

Rich Buggy's Blog: Dynamic forms using Zend_Form

Arvind Bhardwaj's Blog: How to Test PHP Emails on Localhost


Community Events

Don't see your event here?
Let us know!


laravel language interview unittest voicesoftheelephpant install podcast opinion api php7 extension laravel5 series example introduction framework release community xdebug library

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework