i am thinking of using Zend_Auth as the Authentication "mechanism" (component) for a web site. After a quick look a realized that for Database Table Authentication i will also have to use the Zend_Db component.
Has anyone tried this approac开发者_高级运维h? Am i forced to use and/or extend/implement the Zend_DB methods/interfaces in order to have Zend_Auth integrated in a web site (web application?).
Can i plug-in my own DB Abstraction layer into the Zend_Auth component and instruct Zend_Auth to use it for Database Table Authentication easily? I am trying to figure out if such a solution is worth the effort.
You could do it you just need to write your own Zend_Auth adapter that will make use of your Abastraction layer. Its not really that complex as there arent that many required methods to implement/overload. Ive done it using Doctrine, a raw PDO connection, as well as a Zend_Db based simple ORM. If youre requirements for the actual functionality are minimal you should be able to get it done in a minimal amount of time (hours or minutes as opposed to days).
精彩评论