Zendcasts Forum

A community of developers who work with the Zend Framework and other enterprise PHP technologies

You are not logged in.

#1 2010-02-12 20:41:29

Jon Lebensold
Administrator
Registered: 2009-06-27
Posts: 279

ZC46 – Logging with Timestamps and Doctrine Event Listeners

This short video is going to be the last in my 2009-2010 series on Doctrine 1.2. I'm wrapping it up with a little example of adding timestamps, logging and using Doctrine's event listener architecture.

Grab a copy of the project or browse the repository.

ServerGrove will be sponsoring 3 videos this month! ServerGrove specializes in Zend Framework hosting and they've offered a 10% rebate on hosting with coupon code "zc". If you're looking for a host, be sure to check them out (referral). They've also added an additional coupon for "Mini Hosting" plans, get $2 off by using code "zcmini".

Offline

#2 2010-03-08 22:46:00

Ryan Johnston
Member
Registered: 2010-03-08
Posts: 21

Re: ZC46 – Logging with Timestamps and Doctrine Event Listeners

Hey Jon,

I noticed in this screen cast you mentioned re-factoring the authentication check code into a controller plug-in.

I'm just after your advice of how you might do this?

Would you have an array to specify which controllers require authentication and an array to specify which actions require authentication? So that you can lock out an entire controller or just specific actions?

You've really helped me with learning Zend Framework, thank you!

Cheers,
Ryan

Offline

#3 2010-03-10 16:04:39

Jon Lebensold
Administrator
Registered: 2009-06-27
Posts: 279

Re: ZC46 – Logging with Timestamps and Doctrine Event Listeners

Hey Ryan,

I think that what you're after would depend on the size and design of the application. Ideally, you would just filter access based on modules. This is really easy to do in Zend Controller Plugins. Another way would be to specify your own prefixes to actions that are protected. A more sophisticated approach would be a "role"-based method where each user has a role and a lookup is made against a resource (the action requested) and their own ACL.

Offline

Board footer

Powered by FluxBB