ACL-allow based on aco id

2013-08-01 Thread Michael Gaiser
So I have seen a lot of examples that use the aco alias when calling allow() but they usually have the parent aco's alias included. For example 'controllers/Users'. Is it possible to call allow() and just use the Aco.id and the Aro.id? Thanks ~Michael -- Like Us on FaceBook

is it possible in cakephp to access directory outside of app

2013-08-01 Thread Jignesh Brahmkhatri
I want to access folder outside the app directory for different web application my folder structure is like /public_html/app/public_html/application1/public_html/application2 Url I want is like mydomain.com for app mydomain.com/application1 for application1 mydomain.com/application2 for

Re: Wordpress blog archive look like in CakePHP

2013-08-01 Thread Matt Bowden
One way to approach this is to use a virtual field ( http://book.cakephp.org/2.0/en/models/virtual-fields.html). In your Post model, create a virtual field called year that gets the year out of the created field. On Tuesday, July 30, 2013 4:19:54 PM UTC-7, Helder Lucas wrote: I'm building and

Re: is it possible in cakephp to access directory outside of app

2013-08-01 Thread GS
can't you use alias in apache and map to the folders. Use the alias inside the cake to access those paths??? On Wednesday, 31 July 2013 13:32:04 UTC+1, Jignesh Brahmkhatri wrote: I want to access folder outside the app directory for different web application my folder structure is like

Re: Wordpress blog archive look like in CakePHP

2013-08-01 Thread Matt Bowden
Try creating a virtual field for the year ( http://book.cakephp.org/2.0/en/models/virtual-fields.html) and using the group option in your find method ( http://api.cakephp.org/2.3/class-Model.html#_find). On Tuesday, July 30, 2013 4:19:54 PM UTC-7, Helder Lucas wrote: I'm building and

Re: Cache Help

2013-08-01 Thread Eric Haskins
Here is one of my models for dynamic forms. I hope it helps this is CakePHP 2.x so I clear cache afterSave (editing a forms structure) or afterDelete (selfexplanatory) class Forms extends AppModel { public $primaryKey = 'id'; public function afterSave($created) {

Re: Cache Help

2013-08-01 Thread Reuben
Oh, nice. My original reply was deleted. Anyhoo, I might suggest that you only clear the cache for the particular Form(s) that were deleted or saved, using Cache::delete('getFormsById' . $id). Although you may need to double check the event of multiple Forms being saved or deleted. I think