Re: Problems installing phpGACL for CakePHP 1.2
i'm now currently working with cake 1.2 RC3... i guest phpgacl doesn't work with that cake version... --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Problems installing phpGACL for CakePHP 1.2
On Sep 22, 5:37 pm, Josh <[EMAIL PROTECTED]> wrote: > I'm having a serious problem installing phpGACL on cakephp 1.2: I > can't see the "Proceed with installation" button that I have been told > to click. Is there a way to manually submit the form or to proceed or > to make the button visible? Sounds like you're asking the wrong half of that equation. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Problems installing phpGACL for CakePHP 1.2
same promblem with me.. anyone can help..?? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Problems installing phpGACL for CakePHP 1.2
I'm having a serious problem installing phpGACL on cakephp 1.2: I can't see the "Proceed with installation" button that I have been told to click. Is there a way to manually submit the form or to proceed or to make the button visible? Thanks, Josh --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: phpGACL + 1.2 - Model Errors
The phpGACL plugin is not 1.2 ready yet. I need to dedicate some time to port it. -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de Mike Digital Egg Enviado el: Miércoles, 28 de Noviembre de 2007 02:48 p.m. Para: Cake PHP Asunto: phpGACL + 1.2 - Model Errors Any ideas what is going on? Has anyone else successfully nstalled this plugin on 1.2? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
phpGACL + 1.2 - Model Errors
Hi, I am trying to install the phpGACL plugin by Mariano Iglesias (http:// dev.sypad.com/installing-phpgacl-plugin-cakephp). I have followed the instructions but when i go to http://myurl.com/phpgacl I get the following error: Fatal error: Call to a member function on a non-object in /home/app/ app_controller.php on line 126 Line 126 is just a function which gets called in my main app_controller.php beforeFilter() which contains a findAll mthod on a Model. The model works fine everywhere else. If I take that one out it just finds the next method and causes an error there. Any ideas what is going on? Has anyone else successfully nstalled this plugin on 1.2? Cheers Mike --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Problems setting up phpGACL
I HAVE THE ANSWER! At least, this worked for me after having the same problems. I hope this is timely enough for y'alls. Instead of this URL: http://your.app.name/phpgacl (which, for me, consistently redirected to http://your.app.name/phpgacl/install and then gave the Missing Controller (i.e. "404") error) TRY this URL: http://your.app.name/phpgacl/phpgacl/install TWO phpgacls. Thats what worked for me. i.e. /plugin/controller/action HOWEVER, I am still having problems, as there are some insurmountable errors showing up, as follows: Warning (512): Method PhpgaclHtmlHelper::formTag does not exist [CORE/ cake/libs/view/helper.php, line 148] AND Warning (512): Method PhpgaclHtmlHelper::submit does not exist [CORE/ cake/libs/view/helper.php, line 148] Of course, I am using CakePHP 1.2 and that might be the problem. Oh, well, if anyone has a solution for me, then great. Otherwise, I'm gonna go get a beer. Seeyalater... On Oct 29, 5:46 am, ellils <[EMAIL PROTECTED]> wrote: > Ha... Glad I found another person with the same problems... :) > > I am going to fiddle with it some more and hopefully I can resolve > this install problem. > > Let me know if you discover something? > > Regards, > ellils > > On Oct 29, 5:30 pm, Cavallo <[EMAIL PROTECTED]> wrote: > > > Same problem here. :/ When I go to localhost/phpgacl it redirects me > > to phpgacl/install but then I get that phpgacl controller does not > > exists :/ > > > Best regards. > > > On Oct 28, 10:31 pm, ellils <[EMAIL PROTECTED]> wrote: > > > > Hi fellas, > > > > I know this topic has been discussed several times on this forum... > > > read through everything and tried every conceivable way to get this > > > sorted out on my localhost but for some reason, I could not integrate > > > phpGACL with my cake install. > > > > Hope someone out here could point me in the correct direction. > > > > These are my settings for my cake installation:- > > > Cake library is located at "c:\www\cake\" > > > Web document root is "c:\www\webroot\" > > > App folder is located at "c:\www\webroot\app\" > > > Vendor folder is located at "c:\www\webroot\app\vendor > > > > I downloaded phpgacl_for_cakephp-1.0.2b and copied all the folders > > > into the corresponding ones. > > > > If I point my browser athttp://localhost/Icansee the correct > > > messages: > > > " > > > CakePHP Rapid Development > > > > Your database configuration file is present. > > > > Cake is able to connect to the database." > > > > According to the instructions listed here > > > -http://dev.sypad.com/installing-phpgacl-plugin-cakephp > > > - I should next point my browser at "http://localhost/phpgacl/"; but > > > when I do that, all I get is a 404 page not found error since phpgacl > > > is not located there. > > > > Am I interpreting part of the install instructions wrongly? > > > > TIA, > > > ellils --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Problems setting up phpGACL
Are you using cakephp 1.1? I previously used the phpGACL with success. Since switching to cakephp 1.2, I have migrated to the built-in ACL scheme with a set up similar to what Geoff uses. (http://lemoncake.wordpress.com/2007/07/19/acl-with-groups/) Anyway, take a look at this thread. http://groups.google.com/group/cake-php/browse_thread/thread/99f6800c439146e4 Gary On 10/29/07, ellils <[EMAIL PROTECTED]> wrote: > > Ha... Glad I found another person with the same problems... :) > > I am going to fiddle with it some more and hopefully I can resolve > this install problem. > > Let me know if you discover something? > > Regards, > ellils > > On Oct 29, 5:30 pm, Cavallo <[EMAIL PROTECTED]> wrote: > > Same problem here. :/ When I go to localhost/phpgacl it redirects me > > to phpgacl/install but then I get that phpgacl controller does not > > exists :/ > > > > Best regards. > > > > On Oct 28, 10:31 pm, ellils <[EMAIL PROTECTED]> wrote: > > > > > Hi fellas, > > > > > I know this topic has been discussed several times on this forum... > > > read through everything and tried every conceivable way to get this > > > sorted out on my localhost but for some reason, I could not integrate > > > phpGACL with my cake install. > > > > > Hope someone out here could point me in the correct direction. > > > > > These are my settings for my cake installation:- > > > Cake library is located at "c:\www\cake\" > > > Web document root is "c:\www\webroot\" > > > App folder is located at "c:\www\webroot\app\" > > > Vendor folder is located at "c:\www\webroot\app\vendor > > > > > I downloaded phpgacl_for_cakephp-1.0.2b and copied all the folders > > > into the corresponding ones. > > > > > If I point my browser athttp://localhost/Ican see the correct > > > messages: > > > " > > > CakePHP Rapid Development > > > > > Your database configuration file is present. > > > > > Cake is able to connect to the database." > > > > > According to the instructions listed here > > > -http://dev.sypad.com/installing-phpgacl-plugin-cakephp > > > - I should next point my browser at "http://localhost/phpgacl/"; but > > > when I do that, all I get is a 404 page not found error since phpgacl > > > is not located there. > > > > > Am I interpreting part of the install instructions wrongly? > > > > > TIA, > > > ellils > > > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Problems setting up phpGACL
Ha... Glad I found another person with the same problems... :) I am going to fiddle with it some more and hopefully I can resolve this install problem. Let me know if you discover something? Regards, ellils On Oct 29, 5:30 pm, Cavallo <[EMAIL PROTECTED]> wrote: > Same problem here. :/ When I go to localhost/phpgacl it redirects me > to phpgacl/install but then I get that phpgacl controller does not > exists :/ > > Best regards. > > On Oct 28, 10:31 pm, ellils <[EMAIL PROTECTED]> wrote: > > > Hi fellas, > > > I know this topic has been discussed several times on this forum... > > read through everything and tried every conceivable way to get this > > sorted out on my localhost but for some reason, I could not integrate > > phpGACL with my cake install. > > > Hope someone out here could point me in the correct direction. > > > These are my settings for my cake installation:- > > Cake library is located at "c:\www\cake\" > > Web document root is "c:\www\webroot\" > > App folder is located at "c:\www\webroot\app\" > > Vendor folder is located at "c:\www\webroot\app\vendor > > > I downloaded phpgacl_for_cakephp-1.0.2b and copied all the folders > > into the corresponding ones. > > > If I point my browser athttp://localhost/Ican see the correct > > messages: > > " > > CakePHP Rapid Development > > > Your database configuration file is present. > > > Cake is able to connect to the database." > > > According to the instructions listed here > > -http://dev.sypad.com/installing-phpgacl-plugin-cakephp > > - I should next point my browser at "http://localhost/phpgacl/"; but > > when I do that, all I get is a 404 page not found error since phpgacl > > is not located there. > > > Am I interpreting part of the install instructions wrongly? > > > TIA, > > ellils --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Problems setting up phpGACL
Same problem here. :/ When I go to localhost/phpgacl it redirects me to phpgacl/install but then I get that phpgacl controller does not exists :/ Best regards. On Oct 28, 10:31 pm, ellils <[EMAIL PROTECTED]> wrote: > Hi fellas, > > I know this topic has been discussed several times on this forum... > read through everything and tried every conceivable way to get this > sorted out on my localhost but for some reason, I could not integrate > phpGACL with my cake install. > > Hope someone out here could point me in the correct direction. > > These are my settings for my cake installation:- > Cake library is located at "c:\www\cake\" > Web document root is "c:\www\webroot\" > App folder is located at "c:\www\webroot\app\" > Vendor folder is located at "c:\www\webroot\app\vendor > > I downloaded phpgacl_for_cakephp-1.0.2b and copied all the folders > into the corresponding ones. > > If I point my browser athttp://localhost/I can see the correct > messages: > " > CakePHP Rapid Development > > Your database configuration file is present. > > Cake is able to connect to the database." > > According to the instructions listed here > -http://dev.sypad.com/installing-phpgacl-plugin-cakephp > - I should next point my browser at "http://localhost/phpgacl/"; but > when I do that, all I get is a 404 page not found error since phpgacl > is not located there. > > Am I interpreting part of the install instructions wrongly? > > TIA, > ellils --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Problems setting up phpGACL
Hi fellas, I know this topic has been discussed several times on this forum... read through everything and tried every conceivable way to get this sorted out on my localhost but for some reason, I could not integrate phpGACL with my cake install. Hope someone out here could point me in the correct direction. These are my settings for my cake installation:- Cake library is located at "c:\www\cake\" Web document root is "c:\www\webroot\" App folder is located at "c:\www\webroot\app\" Vendor folder is located at "c:\www\webroot\app\vendor I downloaded phpgacl_for_cakephp-1.0.2b and copied all the folders into the corresponding ones. If I point my browser at http://localhost/ I can see the correct messages: " CakePHP Rapid Development Your database configuration file is present. Cake is able to connect to the database." According to the instructions listed here - http://dev.sypad.com/installing-phpgacl-plugin-cakephp - I should next point my browser at "http://localhost/phpgacl/"; but when I do that, all I get is a 404 page not found error since phpgacl is not located there. Am I interpreting part of the install instructions wrongly? TIA, ellils --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: phpGACL and params in action.
Who used phpgacl-cake component? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
phpGACL and params in action.
Hello guys, please say me, how i can make rule for PHPGacl. I need DENY /news/view/123, and ALLOW all another articles, but i don't see this features in PHPGACL CAke Control panel. I try make Controllable Elements (AXOs) as view(123) and view/123,but it's not work. Help me please. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: PHPGacl adn params in action
I try make Controllable Elements (AXOs) as view(123) and view/123, but it's not work. Help me please. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
PHPGacl adn params in action
Hello guys, please say me, how i can make rule for PHPGacl. I need DENY /news/view/123, and ALLOW all another articles, but i don't see this features in PHPGACL CAke Control panel. I try ьфлу Controllable Elements (AXOs) as view(123) and view/123, but it's not work. Help me please. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
A problem with phpgacl
hello guys, i have some problems with the phpgacl extension. I want to display all users of a group. The problem is, i dont know how i can do it right now. I need this feature for a private messaging system. has anyone a good solution for this problem? i tested some functions in the component api but it doesnt work. thanks for your reply.. Daniel --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Update phpGACL when a user signs up
Thank's alot, both of you! I'll try it out as soon as I get home from work. Regards, Andreas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
phpgacl for CakePHP problem in Cake 1.2
Hey, I'm using Cake 1.2 with phpgacl for CakePHP 1.0.2b and I've been having a problem adding permissions. I have fixed a lot of the 1.1 to 1.2 conversion errors, but it's obviously not liking something in either the plugin or the vendor lib itself and is failing to update the database, so it throws a flash error. Has anyone successfully gotten phpgacl for CakePHP to work for Cake 1.2? Is there another plugin that you would recommend for ACL that would give me an actual user interface to assign permissions to groups and users with? Every ACL tutorial I've read has only repeated the same things, in a way that I still don't understand much of it. I know it sounds rash, but I don't have the time to commit to trying to understand ACL the old fashioned way and writing a lib to control it for me. If you think you can help me on either fronts, please let me know. I can send you whatever files you need. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Update phpGACL when a user signs up
On 7/1/07, Andreas <[EMAIL PROTECTED]> wrote: > > > I'm using CakePHP 1.1 with phpGACL. I've only tried out Cake for the > last days and now I've finally got an sign up form to work as > expected. But how do I update the corresponding phpGACL tables when a > new user signs up? [..snip..] phpGACL being pretty extensive I'm sure there has to be an easy way of > doing this? (Besides manually using the Import Groups / Users > function) The way I do it is to use the methods provided by the PhpGacl component. eg: function add_user() { // do stuff in your app to add the user.. then: $this->PhpGacl->saveUser( $this->User->getLastInsertID(), $fullUsersName, false ); } You should look at the code in the component to find out what other methods you can use (delete user from PhpGacl, etc). - Gonzalo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: Update phpGACL when a user signs up
phpGACL comes with an extensive API. Look at the functions available in the PhpGacl component. To save a user, for example, you would do: $this->PhpGacl->saveUser($userId, $userName); For example if you just created a User with ID #15, then you can do: $this->PhpGacl->saveUser(15, 'User #15'); The second parameter is just a descriptive name to use inside phpGACL Plugin administration. -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de Andreas Enviado el: Domingo, 01 de Julio de 2007 07:33 a.m. Para: Cake PHP Asunto: Update phpGACL when a user signs up I'm using CakePHP 1.1 with phpGACL. I've only tried out Cake for the last days and now I've finally got an sign up form to work as expected. But how do I update the corresponding phpGACL tables when a new user signs up? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Update phpGACL when a user signs up
I'm using CakePHP 1.1 with phpGACL. I've only tried out Cake for the last days and now I've finally got an sign up form to work as expected. But how do I update the corresponding phpGACL tables when a new user signs up? My users table looks like: CREATE TABLE `users` ( `id` int(10) unsigned NOT NULL auto_increment, `username` varchar(20) NOT NULL default '', `password` varchar(40) NOT NULL default '', `email` varchar(50) default NULL, `created` datetime default NULL, PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=15 ; and the action looks like function signup() { if (!empty($this->data)) { if ($this->User->save($this->data)) { $this->flash('Grattis! Nu är du medlem.', '/users/ login'); } } } phpGACL being pretty extensive I'm sure there has to be an easy way of doing this? (Besides manually using the Import Groups / Users function) Regards, Andreas --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
More on strange phpgacl behaviour
Hi, I've just discovered that the problem I just posted about may be related to the fact that the content I was looking at had some links to non-existant images (eg. /img/blah.gif). After digging through a lot of CakePHP code, I found where the dispatcher makes some calls to fire up controllers and part of this is the firing up of components (like, phpgacl), which is the one that interfeers and blocks the request. If the file doesn't exist, phpgacl gets in the way of a "Error 404" page and sends me to the "denied" callback instead. If the /img/ file exists, then it's fine. Any ideas how to fix this?? I'd really appreciate any suggestions as I've dug through lots of CakePHP code and still can't figure out the right solution. Thanks in advance. Regards, Gonzalo. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
phpgacl + strange setFlash behaviour
Hi All, I've been using PHPGACL with CakePHP (using Mariano's plug-in) and I'm experiencing some strange behaviour in regards to the flash messages. I'll explain what I mean, but first, my app_controller.php 's relevant parts: var $gacl = array( 'get' => array( 'type' => 'session', 'value' => 'User.id' ), 'denied' => array( 'type' => 'callback', 'value' => '_accessDenied' ) ); function _accessDenied() { if( $this->Session->check( 'User.username' ) ) { // user is logged in so lets just flash an access denied $this->Session->setFlash( 'Access Denied', 'flash_error' ); return $this->redirect( $this->referer( '/home' ) ); } else { // not logged in, so we send to the login page return $this->redirect( '/users/login' ); } } So the idea is, if they access any page at all, it will check the session for User.id. If not found, it will go to the _accessDenied callback which checks if the User.username has been set (kinda pointless since it's already checking for User.id, but anyway, I'm sure I did it for a reason). If so, it means the user is logged in so we flash a simple Access Denied error. If the user is not logged in, we redirect them to /users/login. There used to be a setFlash call before the redirect but I took it out because of this strange behaviour (which is now happening with "Access Denied" too). What happens is I'll go and access protected page. It rejects me as it should so I get an access denied message and the redirect works. That access denied flash doesn't leave $_SESSION (did some debug'ing) at all, it stays there even after $session->flash() has been called. Now that I think about it, this only seems to happen in controllers where I overwrite the $gacl variable (because of some special requirement for that controller to define $gacl differently). Could this be the reason? is it a bad idea to redefine the $gacl variable in another controller? As far as I know, it should simply "replace" the $gacl definition of app_controller or am I totally wrong? Thanks in advance for any help. - Gonzalo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Problems installing phpGACL-Plugin with Cake
Search this group for: "phpGACL could not be installed" On 5/18/07, JuergenE <[EMAIL PROTECTED]> wrote: > > Hello group > > I have spent hours trying to install phpGACL-Plugin with CakePHP and I > have spent hours to find a solution. > > I use CakePHP 1.1.14.4797, phpGACL Plugin 1.0.2b, phpGACL 3.3.7, PHP > 5.1.4 on my local server and MySQL 4.1.20. > I use the document http://dev.sypad.com/installing-phpgacl-plugin-cakephp > for installation. I only get to the page that says "Check your > settings" and shows my database-settings. When I click on "Proceed > with Installation", the page reloads presenting an error-message on > top ("phpGACL could not be installed"). Looking at the database-table, > there are 4 tables, that the script created (prefix_acl, > prefix_acl_sections, prefix_aco, prefix_phpgacl). > > Has anybody any hint for me how to get the plugin installed and > working? > > Thanks > JuergenE > > > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Problems installing phpGACL-Plugin with Cake
Hello group I have spent hours trying to install phpGACL-Plugin with CakePHP and I have spent hours to find a solution. I use CakePHP 1.1.14.4797, phpGACL Plugin 1.0.2b, phpGACL 3.3.7, PHP 5.1.4 on my local server and MySQL 4.1.20. I use the document http://dev.sypad.com/installing-phpgacl-plugin-cakephp for installation. I only get to the page that says "Check your settings" and shows my database-settings. When I click on "Proceed with Installation", the page reloads presenting an error-message on top ("phpGACL could not be installed"). Looking at the database-table, there are 4 tables, that the script created (prefix_acl, prefix_acl_sections, prefix_aco, prefix_phpgacl). Has anybody any hint for me how to get the plugin installed and working? Thanks JuergenE --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: "phpGACL could not be installed"
Trying to install phpGACL without the plugin produced detailed error messages and, oh, I'm so embarrassed. I could make up a story about how I fixed it but it's far too complex to explain in detail. Or I could come clean and admit that I was connecting to the database as a basic user without 'create table' privileges. D'oh! My apologies to you all for wasting your time. If it's any consolation, the plugin seems to work well so far in 1.2, albeit with lots of 'HtmlHelper is deprecated' messages in development mode. I also got the original schema.xml to work fine with my UTF8 database. So thank you for your quick responses (and for the plugin itself) and sorry again. Rest assured I'll spend the rest of the day looking suitably sheepish. Tagawa --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: "phpGACL could not be installed"
On 17.05.2007 07:57 tagawa wrote: > Hello, > I'm developing a new site using CakePHP 1.2, dAuth and hopefully > phpGACL. Having upload the CakePHP phpGACL plugin and phpGACL itself, > clicking the 'Proceed with installation' button results in the error > message "phpGACL could not be installed". Looking at the code, this > happens when schema.xml is parsed and executed but I'd like more > details. Is there a way to get the phpGACL plugin to print a log of > what's going on or print error messages from phpGACL itself? > Are you using UTF8 tables? The phpGACL install script creates indexes that are over 1000 bytes when using Unicode, and 1000 bytes is the size limit for indexes in MySQL. Thus, the whole table creation fails. Either set your database to use a single-byte charset, or change the schema.xml to create smaller indexes. -Matt --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: "phpGACL could not be installed"
I had similar problems and determined the issue to be with phpGACL trying to create overly large index keys for that version of MySQL. To view the error messages, try installing phpGACL directly. I overcame the problem by editing the schema.xml. No problems in production usage. For example: section_value value hidden I am using cake 1.1. So as MI states it is not compatible with 1.2, believe it. Gary On 5/17/07, tagawa <[EMAIL PROTECTED]> wrote: > > Hello, > I'm developing a new site using CakePHP 1.2, dAuth and hopefully > phpGACL. Having upload the CakePHP phpGACL plugin and phpGACL itself, > clicking the 'Proceed with installation' button results in the error > message "phpGACL could not be installed". Looking at the code, this > happens when schema.xml is parsed and executed but I'd like more > details. Is there a way to get the phpGACL plugin to print a log of > what's going on or print error messages from phpGACL itself? > > Here's what I've checked: > * The database settings are OK. > * The error occurs with or without using table prefixes > * schema.xml exists in app/vendors/phpgacl > * I put my database details in gacl.ini.php (although I don't think > this is necessary) > * I am sober > > My settings are: > CakePHP 1.2 > PHP 4.3 > MySQL 4.1 > > As mentioned, I believe the problem is that I'm using CakePHP 1.2 in > which case it would be worthwhile trying to make it compatible. > Either that or it's something embarrassingly simple. > Thanks in advance for any assistance. > > > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: "phpGACL could not be installed"
I have not even tested it with CakePHP 1.2 and I am sure it wouldn't work, since for example the plugin forms are not 1.2 compatible. I need to find the time to create a new branch for 1.2 And yes, you do not need to touch any setting in phpGACL directory, it will automatically set your DB from your app/config/database.php -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de tagawa Enviado el: Jueves, 17 de Mayo de 2007 02:57 a.m. Para: Cake PHP Asunto: "phpGACL could not be installed" As mentioned, I believe the problem is that I'm using CakePHP 1.2 in which case it would be worthwhile trying to make it compatible. Either that or it's something embarrassingly simple. Thanks in advance for any assistance. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
"phpGACL could not be installed"
Hello, I'm developing a new site using CakePHP 1.2, dAuth and hopefully phpGACL. Having upload the CakePHP phpGACL plugin and phpGACL itself, clicking the 'Proceed with installation' button results in the error message "phpGACL could not be installed". Looking at the code, this happens when schema.xml is parsed and executed but I'd like more details. Is there a way to get the phpGACL plugin to print a log of what's going on or print error messages from phpGACL itself? Here's what I've checked: * The database settings are OK. * The error occurs with or without using table prefixes * schema.xml exists in app/vendors/phpgacl * I put my database details in gacl.ini.php (although I don't think this is necessary) * I am sober My settings are: CakePHP 1.2 PHP 4.3 MySQL 4.1 As mentioned, I believe the problem is that I'm using CakePHP 1.2 in which case it would be worthwhile trying to make it compatible. Either that or it's something embarrassingly simple. Thanks in advance for any assistance. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: PhpGacl component license
I see. Thank you! //Michel On May 16, 2:59 am, "Mariano Iglesias" <[EMAIL PROTECTED]> wrote: > It's released under the same license as CakePHP: MIT. > > -MI > > --- > > Remember, smart coders answer ten questions for every question they ask. > So be smart, be cool, and share your knowledge. > > BAKE ON! > > blog:http://www.MarianoIglesias.com.ar > > -Mensaje original- > De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre > de Hubbo > Enviado el: Martes, 15 de Mayo de 2007 09:53 p.m. > Para: Cake PHP > Asunto:PhpGaclcomponent license > > What license, if any, are you planning to use for yourPhpGacl > component? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: PhpGacl component license
It's released under the same license as CakePHP: MIT. -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de Hubbo Enviado el: Martes, 15 de Mayo de 2007 09:53 p.m. Para: Cake PHP Asunto: PhpGacl component license What license, if any, are you planning to use for your PhpGacl component? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
PhpGacl component license
This question is for Mariano Iglesias but I guess there will be others wanting to know the answer too. I have been looking at various solutions for a permission system for our company project and have come to the conclusion that we will be using phpGACL. I see that Mariano already has made a component and after some testing we see that it, with some future modifications, probably will fill some of the basic functionality we need. However, we can't use the code until we know in what license you plan to distribute it with it. What license, if any, are you planning to use for your PhpGacl component? With best regards, Michel --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: Plugin Controller name uniqueness. was: phpGACL installation
Again, I was just kidding around. Let it go, mate, let it go. I'll promise I'll send you some beauty creams ;) -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de AD7six Enviado el: Jueves, 10 de Mayo de 2007 08:24 a.m. Para: Cake PHP Asunto: Re: Plugin Controller name uniqueness. was: phpGACL installation Only when I've run out of beauty creams ;). No, I don't know to what you are referring - I should approach it how..? Obviously I wouldn't create an enhancement ticket for something I don't agree with (although I believe there are plans already afoot for some changes), so ...? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Plugin Controller name uniqueness. was: phpGACL installation
On 10 mayo, 13:17, "Mariano Iglesias" <[EMAIL PROTECTED]> wrote: > Oh come on, don't give me that freedom of speech BS, just kidding around. > Sensitive day? Only when I've run out of beauty creams ;). No, I don't know to what you are referring - I should approach it how..? Obviously I wouldn't create an enhancement ticket for something I don't agree with (although I believe there are plans already afoot for some changes), so ...? Cheers, AD --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: Plugin Controller name uniqueness. was: phpGACL installation
Oh come on, don't give me that freedom of speech BS, just kidding around. Sensitive day? -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de AD7six Enviado el: Jueves, 10 de Mayo de 2007 08:10 a.m. Para: Cake PHP Asunto: Re: Plugin Controller name uniqueness. was: phpGACL installation I don't feel that expressing a different opinion is an inappropriate approach. Or you mean something different..? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: Plugin Controller name uniqueness. was: phpGACL installation
I'm not a core developer, I'm a contributor reporting to all-mighty nut. -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de Dr. Tarique Sani Enviado el: Jueves, 10 de Mayo de 2007 08:14 a.m. Para: cake-php@googlegroups.com Asunto: Re: Plugin Controller name uniqueness. was: phpGACL installation MI is just showing signs of being a core CakePHP developer - just let him be :P --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Plugin Controller name uniqueness. was: phpGACL installation
On 5/10/07, AD7six <[EMAIL PROTECTED]> wrote: > > I don't feel that expressing a different opinion is an inappropriate > approach. Or you mean something different..? > MI is just showing signs of being a core CakePHP developer - just let him be :P Tarique P.S. Cheesecake shouldn't have been called a plugin in the first place -- = PHP for E-Biz: http://sanisoft.com Cheesecake-Photoblog needs you!: http://cheesecake-photoblog.org = --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Plugin Controller name uniqueness. was: phpGACL installation
On 10 mayo, 13:00, "Mariano Iglesias" <[EMAIL PROTECTED]> wrote: > Now we're talking. > > See Andy? That's how you should approach it ;) ? I don't feel that expressing a different opinion is an inappropriate approach. Or you mean something different..? cheers, AD --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: Plugin Controller name uniqueness. was: phpGACL installation
Now we're talking. See Andy? That's how you should approach it ;) -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de Dr. Tarique Sani Enviado el: Jueves, 10 de Mayo de 2007 07:41 a.m. Para: cake-php@googlegroups.com Asunto: Re: Plugin Controller name uniqueness. was: phpGACL installation On 5/10/07, Mariano Iglesias <[EMAIL PROTECTED]> wrote: > > Why should I not? What's wrong about it? If I build a plugin I decide what > is available to my application. And using requestAction() is perfectly > acceptable and under some circumstances even recommended. > Agreed and that exactly is why, hell should not break loose If in my application I have a UsersController, and need to do a requestAction() to a plugin's UsersController. An enhancement ticket in trac will be an acceptable end to the thread? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Plugin Controller name uniqueness. was: phpGACL installation
On 5/10/07, Mariano Iglesias <[EMAIL PROTECTED]> wrote: > > Why should I not? What's wrong about it? If I build a plugin I decide what > is available to my application. And using requestAction() is perfectly > acceptable and under some circumstances even recommended. > Agreed and that exactly is why, hell should not break loose If in my application I have a UsersController, and need to do a requestAction() to a plugin's UsersController. An enhancement ticket in trac will be an acceptable end to the thread? Cheers Tarique -- = PHP for E-Biz: http://sanisoft.com Cheesecake-Photoblog needs you!: http://cheesecake-photoblog.org = --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Plugin Controller name uniqueness. was: phpGACL installation
On 10 mayo, 12:23, AD7six <[EMAIL PROTECTED]> wrote: > things which are app wide like, for example, user management or access Oops Freudian slip there. user management -> authentication User management is in itself a good example of what a plugin can be used for. AD --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: Plugin Controller name uniqueness. was: phpGACL installation
Why should I not? What's wrong about it? If I build a plugin I decide what is available to my application. And using requestAction() is perfectly acceptable and under some circumstances even recommended. So where's the sin? -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de AD7six Enviado el: Jueves, 10 de Mayo de 2007 07:24 a.m. Para: Cake PHP Asunto: Plugin Controller name uniqueness. was: phpGACL installation > If in my application I have a UsersController, and need to do a > requestAction() to a plugin's UsersController, then hell breaks loose. Why would you want to do that? Because something is a technical possibility, I don't feel that should be the basis for giving Plugin controllers 'unique' names. having inbuilt namespaces for plugins would completely avoid the issue though (which of course would involve cake expecting plugin controllers to be named differently). --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Plugin Controller name uniqueness. was: phpGACL installation
HI all, On 10 mayo, 10:49, "Mariano Iglesias" <[EMAIL PROTECTED]> wrote: > Fromhttp://manual.cakephp.org/chapter/plugins: > > "While it isn't required, it is recommended that you name your plugin > controllers something relatively unique in order to avoid namespace > conflicts with parent applications. Its not a stretch to think that a parent > application might have a UsersController, OrderController, or > ProductController: so you might want to be creative with controller names, > or prepend the name of the plugin to the classname" I don't feel that advice is appropriate. The only means of normally generating a pseudo-conflict is if you have an app controller with the same name as a plugin - in that case in the absence of a specific route the app controller will be used for the url /plugin_name/. but that's not really a problem - just a side effect of bad (user) design. > If in my application I have a UsersController, and need to do a > requestAction() to a plugin's UsersController, then hell breaks loose. Why would you want to do that? Because something is a technical possibility, I don't feel that should be the basis for giving Plugin controllers 'unique' names. having inbuilt namespaces for plugins would completely avoid the issue though (which of course would involve cake expecting plugin controllers to be named differently). A plugin is supposed to be a self contained mini (although in reality it doesn't have to be mini at all) application, in principle there shouldn't be any intereractions such as the above between a plugin and the app/another plugin. If you have a controller with the same name in a plugin and in your app, unless you 1) explicitly use loadControllers in the plugin 2) explicitly load and try to use the plugin xyz controller from the app xyz controller 3) requestAction from app xyz controller to plugin xzy controller (why would anyone want to do that?) 4) requestAction from plugin xyz controller to app xzy controller (why would anyone want to do that?) 5) requestAction from one plugin xyz controller to a different plugin xyz controller (why would anyone want to do that?) You won't come across any issues at all. I feel that only the misuse of requestAction can cause issues, and that's the basis for my disagreeing with the manual page on plugin controller name uniqueness. I should perhaps add that I don't think any plugin should contain things which are app wide like, for example, user management or access control. However a shop plugin shouldn't, for example, need to care / at all/ about having a products controller since as a user who has just installed the 'shop' plugin why would you then either a) butcher the plugin to look at your app controllers or b) start using request action in your app xyz controller to look at the plugin xyz controller or c) something else a bit wacky? If someones app controller makes a requestAction call for all requests that could indeed make this sort of problem apparent; But again: I'd file that under misuse of requestAction. All IMO of course. If I've made a mistake (i.e. not just a difference of opinion) of any kind in my post please let me know. To finish on a q: Has anyone had a specific problem of the type being discussed? Cheers, AD PS. Is there a consensus on top posting? I don't like it :D! (Lamby where are you and your informative footer :)) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: phpGACL installation
On 5/10/07, Mariano Iglesias <[EMAIL PROTECTED]> wrote: > > From http://manual.cakephp.org/chapter/plugins: > > "While it isn't required, it is recommended that you name your plugin > controllers something relatively unique in order to avoid namespace > conflicts with parent applications. Its not a stretch to think that a parent > application might have a UsersController, OrderController, or > ProductController: so you might want to be creative with controller names, > or prepend the name of the plugin to the classname" Ugh! wonder how I missed it... But again IMO the framework should handle this gracefully. Prepending or appending classname is not an answer as it will lead to ugly/confusing/funny URLs or the developers will have to use routes which is not so bad BUT for apps where plugins are supposed to be plug and play expecting end users to edit routes is not an acceptable option. Hmmm... DB based routing anyone? Just my 2ps Tarique -- = PHP for E-Biz: http://sanisoft.com Cheesecake-Photoblog needs you!: http://cheesecake-photoblog.org = --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: phpGACL installation
>From http://manual.cakephp.org/chapter/plugins: "While it isn't required, it is recommended that you name your plugin controllers something relatively unique in order to avoid namespace conflicts with parent applications. Its not a stretch to think that a parent application might have a UsersController, OrderController, or ProductController: so you might want to be creative with controller names, or prepend the name of the plugin to the classname" If in my application I have a UsersController, and need to do a requestAction() to a plugin's UsersController, then hell breaks loose. -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de Dr. Tarique Sani Enviado el: Jueves, 10 de Mayo de 2007 04:17 a.m. Para: cake-php@googlegroups.com Asunto: Re: phpGACL installation Sorry I disagree on the point that uniqueness of plugin controller name should/would be a requisite for it to be plug and play --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: phpGACL installation
On 5/9/07, Mariano Iglesias <[EMAIL PROTECTED]> wrote: > point. Plugin controllers should be named as unique as possible, because > that's the idea of plugins: you drop it on any application and it should > avoid collisions as much as possible. Sorry I disagree on the point that uniqueness of plugin controller name should/would be a requisite for it to be plug and play It is merely a matter of referring to the said controller as plugin/controllername which the framework already manages (?) And yeah it is demeaning for an app to be referred as a plugin :)) Cheers Tarique -- = PHP for E-Biz: http://sanisoft.com Cheesecake-Photoblog needs you!: http://cheesecake-photoblog.org = --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: phpGACL installation
Oh yeah, that's right. Thanks. -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de Sliv Enviado el: Miércoles, 09 de Mayo de 2007 11:22 a.m. Para: Cake PHP Asunto: Re: phpGACL installation When I installed your plugin, I was running 1.1.14.4797 and got the error described in ticket 2370: http://groups.google.com/group/tickets-cakephp/browse_thread/thread/40546c19 50d1d70f/5f9d2360f5e31f95?lnk=gst&q=%232370&rnum=1#5f9d2360f5e31f95 So I implemented the fix and no problems. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: phpGACL installation
Mariano: When I installed your plugin, I was running 1.1.14.4797 and got the error described in ticket 2370: http://groups.google.com/group/tickets-cakephp/browse_thread/thread/40546c1950d1d70f/5f9d2360f5e31f95?lnk=gst&q=%232370&rnum=1#5f9d2360f5e31f95 So I implemented the fix and no problems. On May 9, 9:36 am, "Mariano Iglesias" <[EMAIL PROTECTED]> wrote: > What datasource fix? > > -MI > > --- > > Remember, smart coders answer ten questions for every question they ask. > So be smart, be cool, and share your knowledge. > > BAKE ON! > > blog:http://www.MarianoIglesias.com.ar > > -Mensaje original- > De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre > de Sliv > Enviado el: Miércoles, 09 de Mayo de 2007 10:05 a.m. > Para: Cake PHP > Asunto: Re: phpGACL installation > > ...I don't think I had to do anything else to get it working (other > than that datasource fix) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: phpGACL installation
AD7six: can you have your answer posted above the original mail quote? :) Regarding Cheesecake being an application, AD7six has a point. Don't want to piss Tarique off. Regarding plugins (even though Cheesecake is not one AFAIK) Gonzalo has a point. Plugin controllers should be named as unique as possible, because that's the idea of plugins: you drop it on any application and it should avoid collisions as much as possible. -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de AD7six Enviado el: Miércoles, 09 de Mayo de 2007 10:35 a.m. Para: Cake PHP Asunto: Re: phpGACL installation Why not - cheesecake isn´t a plugin btw, it's an app. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: phpGACL installation
On 5/9/07, AD7six <[EMAIL PROTECTED]> wrote: > > > > > I had one problem with it which I was able to fix pretty easily. I had > an > > old installation of Cheesecake in the plugins dir which had an > > UsersController. My CakePHP app also has an UsersController so it > clashed. > > You'd have to be pretty unlucky to face this sort of issue but, I did :) > I > > think it is more Cheesecake's fault than anyone elses as you're not > supposed > > to use common names like UsersController as plugin controller names. > > Why not - cheesecake isn´t a plugin btw, it's an app. Oh, I guess it now makes sense then :) Cheers Gonzalo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: phpGACL installation
What datasource fix? -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -Mensaje original- De: cake-php@googlegroups.com [mailto:[EMAIL PROTECTED] En nombre de Sliv Enviado el: Miércoles, 09 de Mayo de 2007 10:05 a.m. Para: Cake PHP Asunto: Re: phpGACL installation ...I don't think I had to do anything else to get it working (other than that datasource fix) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: phpGACL installation
On May 9, 3:18 pm, "Gonzalo Servat" <[EMAIL PROTECTED]> wrote: > On 5/9/07, Sliv <[EMAIL PROTECTED]> wrote: > > > > > > > Well, I used PhpGACL 3.3.7 installed into APP_DIR . /vendors/ > > > After extraction, I did have to make a symbolic link to the > > phpgacl-3.3.7 folder called 'phpgacl' because the plugin was looking > > for that folder. > > > For the plugin: > > > app_dir . /plugins/phpgacl/ > > > app_dir . /components/php_gacl.php > > > WEBROOT . /css/phpgacl/ > > WEBROOT . /img/phpgacl/ > > > a while back there was a post that talked about updating the > > webroot . /js/vendors.php to revision 4409 > > > ...I don't think I had to do anything else to get it working (other > > than that datasource fix) > > I had one problem with it which I was able to fix pretty easily. I had an > old installation of Cheesecake in the plugins dir which had an > UsersController. My CakePHP app also has an UsersController so it clashed. > You'd have to be pretty unlucky to face this sort of issue but, I did :) I > think it is more Cheesecake's fault than anyone elses as you're not supposed > to use common names like UsersController as plugin controller names. Why not - cheesecake isn´t a plugin btw, it's an app. AD --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: phpGACL installation
On 5/9/07, Sliv <[EMAIL PROTECTED]> wrote: > > > Well, I used PhpGACL 3.3.7 installed into APP_DIR . /vendors/ > > After extraction, I did have to make a symbolic link to the > phpgacl-3.3.7 folder called 'phpgacl' because the plugin was looking > for that folder. > > For the plugin: > > app_dir . /plugins/phpgacl/ > > app_dir . /components/php_gacl.php > > WEBROOT . /css/phpgacl/ > WEBROOT . /img/phpgacl/ > > a while back there was a post that talked about updating the > webroot . /js/vendors.php to revision 4409 > > ...I don't think I had to do anything else to get it working (other > than that datasource fix) > I had one problem with it which I was able to fix pretty easily. I had an old installation of Cheesecake in the plugins dir which had an UsersController. My CakePHP app also has an UsersController so it clashed. You'd have to be pretty unlucky to face this sort of issue but, I did :) I think it is more Cheesecake's fault than anyone elses as you're not supposed to use common names like UsersController as plugin controller names. Cheers, Gonzalo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: phpGACL installation
Well, I used PhpGACL 3.3.7 installed into APP_DIR . /vendors/ After extraction, I did have to make a symbolic link to the phpgacl-3.3.7 folder called 'phpgacl' because the plugin was looking for that folder. For the plugin: app_dir . /plugins/phpgacl/ app_dir . /components/php_gacl.php WEBROOT . /css/phpgacl/ WEBROOT . /img/phpgacl/ a while back there was a post that talked about updating the webroot . /js/vendors.php to revision 4409 ...I don't think I had to do anything else to get it working (other than that datasource fix) On May 9, 5:50 am, "Paul R. Zwiers" <[EMAIL PROTECTED]> wrote: > Silv, > > Thanks, so my setup should work. Hmmnz... Which version of phpGACL do you > use? Did you have to edit some things manually or just installed the bunch > like described here:http://dev.sypad.com/installing-phpgacl-plugin-cakephp > > TIA > Paul > > > > > I'm using PHP5, MySQL 5 and CakePHP 1.1.14.4797 with Mariano's phpGACL > > and also dAuth 0.3; no problems. The only thing I had to do was > > implement the connection_manager.php trunk fix to resolve a datasource > > error message. That doesn't sound like your issue, though... > > > On May 8, 9:45 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > > > When the page loads where it extends my database (I did not change > > the > > > database.php) I can click the button to "proceed with installation", > > > it creates the tables and comes right back with the same page ... > > > Seems like it is missing something or something did not work. > > > > TIA > > > Paul --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: phpGACL installation
Silv, Thanks, so my setup should work. Hmmnz... Which version of phpGACL do you use? Did you have to edit some things manually or just installed the bunch like described here: http://dev.sypad.com/installing-phpgacl-plugin-cakephp TIA Paul > > I'm using PHP5, MySQL 5 and CakePHP 1.1.14.4797 with Mariano's phpGACL > and also dAuth 0.3; no problems. The only thing I had to do was > implement the connection_manager.php trunk fix to resolve a datasource > error message. That doesn't sound like your issue, though... > > On May 8, 9:45 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > > When the page loads where it extends my database (I did not change > the > > database.php) I can click the button to "proceed with installation", > > it creates the tables and comes right back with the same page ... > > Seems like it is missing something or something did not work. > > > > TIA > > Paul --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: phpGACL installation
I'm using PHP5, MySQL 5 and CakePHP 1.1.14.4797 with Mariano's phpGACL and also dAuth 0.3; no problems. The only thing I had to do was implement the connection_manager.php trunk fix to resolve a datasource error message. That doesn't sound like your issue, though... On May 8, 9:45 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Just adapting CakePHP, needing a complete auth environment and decided > to use phpGACL with the plugin Mariano developed (nice work!). So far > so good. > > Downloaded all the latest releases, put them in the right folders and > started the plugin. > > When the page loads where it extends my database (I did not change the > database.php) I can click the button to "proceed with installation", > it creates the tables and comes right back with the same page ... > Seems like it is missing something or something did not work. > > Ideas anybody? :-) > > Using PHP5 and MySQL 5 by the way. > > TIA > Paul --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
phpGACL installation
Just adapting CakePHP, needing a complete auth environment and decided to use phpGACL with the plugin Mariano developed (nice work!). So far so good. Downloaded all the latest releases, put them in the right folders and started the plugin. When the page loads where it extends my database (I did not change the database.php) I can click the button to "proceed with installation", it creates the tables and comes right back with the same page ... Seems like it is missing something or something did not work. Ideas anybody? :-) Using PHP5 and MySQL 5 by the way. TIA Paul --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
dAuth, PhpGACL for Cake and MySQL View
I'm working on an authentication/authorization solution for my current project, so am trying to save myself a lot of work by using the dAuth component ( http://bakery.cakephp.org/articles/view/introduction-to-dauth-v0-3 ) and the PhpGACL for Cake plugin ( http://cakeforge.org/projects/phpgacl-cake/ ) First of all, thanks to the developers of these add-ons, I'm having good success so far. Basically, I wanted to customize the solution to meet the project's needs. It won't be needing any ARO's other than Users, and to keep things simple, I decided I wanted dAuth to use the same table for "users" that phpgacl does (e.g. "aro"). However, dAuth needs a password, email and username field and the User model wants a table called "users". I didn't want to have to modify the core code for these add-ons unless absolutely necessary. So, what I did was added two fields to the "aro" table for password and email. Then, I created a MySQL 5 view called "users" which views the "aro" table and uses the alias "username" for the "aro" table's "value" field. My theory is this: Since the "value" field is used as a unique identifier for ARO's by phpgacl, and dAuth wants to make sure "usernames" are unique, why not use the same field? Preliminary tests seem to show that everything works. I've seen older posts by Nate et al. talking about MySQL views not being officially supported. So, I thought maybe I'd run this scenario past the community to see if I'm setting myself up for some kind of trouble I'm not aware of. Many thanks in advance! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
phpGACL
I'd like to use this, but I can't figure out how to access MySQL, because the database is running on a non-standard port. With CakePHP, I can define the host as hostname:port, but this doesn't work with the plugin. It's using ADOdb, and I can't seem to define a port using any of the included drivers. Thanks, Michael Tuzi --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: phpGACL for CakePHP 1.0.2b Released - Integrating phpGACL with CakePHP
CakeForge Project approved: http://cakeforge.org/projects/phpgacl-cake -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
phpGACL for CakePHP 1.0.2b Released - Integrating phpGACL with CakePHP
My fellow bakers, I am still waiting for the approval of my Cakeforge submission, but until then I can give you a ZIP package. So anyway without further, check the installation instructions: http://dev.sypad.com/installing-phpgacl-plugin-cakephp It's a package that offers a Plugin + a Component for CakePHP to allow you to use phpGACL as your Access Control List of choice. It is not meant to replace CakePHP's builtin ACL, but to offer an alternative to those who wish to use phpGACL. You can either use the component by itself and don't use the plugin at all (on which case you should be reading the API docs), or you can use the plugin to simplify your life ;) Further articles for this plugin will be here: http://dev.sypad.com/tag/phpgacl API doc is here: http://dev.sypad.com/projects/phpgacl/api I will be producing a screencast on how to start with a fresh installation of CakePHP and set up: 1. User CRUD. 2. Group CRUD. 3. Posts controller (as given in blog tutorial) 4. Login / Logout 5. Protect CRUD pages with phpGACL. -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: Integrating phpGACL with CakePHP
Ok the programmatic part is about done (missing a few things but nothing that prevents you from already playing with it). I temporarily stored it in: http://bin.cakephp.org/view/577137997 I will add a couple more things to it, then build the plugin for manipulating ACL data through web, and then write an article detailing how to use it. I'm pasting here (sorry for the length) a quick readme file I wrote as help. Note that it doesn't give you the explanation of lots of things that are already available through the component, but the component source code is well-documented so it should help. Scragz, regarding re-using the DB connection, I need to look into it as phpGACL uses ADODB so I need to find out how to provide ADODB with an already open link. Anyway quick readme: INSTALL --- Grab latest copy of phpGACL from http://phpgacl.sourceforge.net/ and extract inside your app/vendors directory on a directory named phpgacl. You can instead extract it on CakePHP's main vendors directory. Don't follow the installation procedure shown on phpGACL, as the component will install the necessary database tables. To let it install for the first time, all you need to do is: 1. Make sure that $autoInitialize is set to true on the component. 2. If you also want your controller/actions to be inserted as available in phpGACL, make sure that $autoInstallControllers is set to true on the component. 3. Add PhpGacl as a component to any controller in your application (or even AppController) using the $components variable, and that's it. 4. Access that controller via your browser. When CakePHP initializes the component, it will check that it first needs to install phpGACL on your database. By default the following information is added to phpGACL when the component is run for the first time: a. An ACO section called "access", with an ACO object called "execute" assigned b. An AXO group called "controller" c. If point 2 above is true, then an AXO section for each controller, and an AXO action for each action in that controller. Note that you won't have to understand all this concepts (ARO, ACO, and AXO) if you use the functions provided by the component. All instructions below will assume that you are executing them on a controller where PhpGacl is added as a component. To let the component be available on all controllers, just add it to your AppController class. ADDING CONTROLLERS TO phpGACL - On step 2 at the installation instructions I've shown you how to let the component install all your controller/actions into phpGACL. However, that action is only run the first time (naturally) and you may even ommit that step as you wish to install the controller information yourself. To install a controller and all its accessible actions into phpGACL, from your controller do: $this->PhpGacl->saveController('Posts'); where 'Posts' is a valid CakePHP controller name (what you specify on the variable $name in the controller.) Note that if the controller wasn't added before to phpGACL, it will be created and all its actions stored. Otherwise only actions that were added will be added to phpGACL. SPECIFYING IDs FOR GROUPS AND USERS --- On the quick notes below you'll see that you have to specify an identifier whenever you are manipulating user or group information. Why is this? Why isn't the component taking care of generating a unique ID? Because the idea of this component is to be integrated with your existing authentication scheme, so you should be already storing users and groups your way. The component adds the necessary layers to provide access control to those users and groups. ADDING/MODIFYING USERS -- To add or modify a user, do: $this->PhpGacl->save($identifier, $name); where $identifier is the identifier of the user you would like to add (any valid string or integer), and $name the name you want to set to the user. If you don't set a name the $identifier will also be used as the name instead. Examples: $this->PhpGacl->save(1, 'mariano.iglesias'); To modify a user's name just set the new name in the $name parameter, keeping the same identifier. To delete a user just do: $this->PhpGacl->del($identifier); ADDING/MODIFYING GROUPS --- To add or modify a group, do: $this->PhpGacl->saveGroup($identifier, $name); where $identifier is the identifier of the group you would like to add (any valid string or integer), and $name the name you want to set to the group. Examples: $this->PhpGacl->saveGroup('authenticated', 'Authenticated'); $this->PhpGacl->saveGroup('editor', 'Editor'); $this->PhpGacl->saveGroup('developer', 'Developer'); You can also specify that a group belongs
Re: Integrating phpGACL with CakePHP
I don't have any experience with phpGacl. How hard do you think it would be to get it using the existing Cake DB connection (for performance reasons)? On Feb 28, 4:16 pm, "Mariano Iglesias" <[EMAIL PROTECTED]> wrote: > Update: still working on this (component is already over 900 lines, > including documentation, which is about 70% of the code). > > When the component runs for the first time it will set up PhpGacl database > schema (so there's no need to do anything other than just include phpGacl on > your vendors directory, and then adding PhpGacl as a component to your > controller), and create AXO groups/AXO objects for each controller/action > (see at the bottom of this message) > > Let me give you a quick view on how you programmatically manipulate your ACL > data: > > // Add groups > > $this->PhpGacl->saveGroup(1, 'my group #1 with ID 1'); > $this->PhpGacl->saveGroup(2, 'my group #1 with ID 2'); > > // Modify group > > $this->PhpGacl->saveGroup(2, 'my group #1 with ID 2 with new name'); > > // Get groups > > $groups = $this->PhpGacl->getGroups(); > > /* > This gets you a threaded array like: > > Array > ( > [0] => Array > ( > [id] => authenticated > [name] => Authenticated > ) > > [1] => Array > ( > [id] => 2 > [name] => my group #1 > ) > > [2] => Array > ( > [id] => 3 > [name] => my group #2 > [children] => Array > ( > [0] => Array > ( > [id] => 5 > [name] => my group #2.1 > ) > > ) > > ) > > [3] => Array > ( > [id] => 4 > [name] => my group #3 > ) > > ) > */ > > // Add user: > > $this->PhpGacl->saveUser(1, 'mariano.iglesias'); > > // Modify user: > > $this->PhpGacl->saveUser(1, 'mariano.iglesias (new)'); > > // Assign groups to user: > > $this->PhpGacl->assign(1, array(1, 2)); > > // Get user groups: > > $this->PhpGacl->getUserGroups(1); > > /* > * This gets you an array like: > * > * Array > * ( > *[0] => 1, > *[1] => 2, > *[2] => authenticated > * ) > */ > > // Change user group assignments: > > $this->PhpGacl->assign(1, array(2, 'authenticated')); > > /* > * After which the previous assigned group #1 will be un-assigned, #2 > * will remain assigned, and 'authenticated' will be added to the assignment > */ > > // Delete group (and related data): > > $this->PhpGacl->delGroup(3); > > /* > * By default if the group has children, they will be added as children > * of this group's parent. But if you call it like: > * > * $this->PhpGacl->delGroup(3, false); > * > * Then the children will also be deleted. > * > * Naturally deleting a group means that assignments with this group are > * also removed > */ > > // Delete user (and related data): > > $this->PhpGacl->delUser(1); > > // Add controller and its actions as AXO objects: > > $this->PhpGacl->saveController('Posts'); > > /* > * It creates an AXO group called Posts, and assigned to them > * one AXO object per action. > * > * If the controller was already added, only new actions are > * added > */ > > Next step I'm working on is the assignment of rules between group -> > controller/action, and user -> controller/action. > > After that wrap phpGACL check, set up a few things, and then release the > first version (without the plugin to manipulate data via GUI) > > -MI > > --- > > Remember, smart coders answer ten questions for every question they ask. > So be smart, be cool, and share your knowledge. > > BAKE ON! > > blog:http://www.MarianoIglesias.com.ar --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
RE: Integrating phpGACL with CakePHP
Update: still working on this (component is already over 900 lines, including documentation, which is about 70% of the code). When the component runs for the first time it will set up PhpGacl database schema (so there's no need to do anything other than just include phpGacl on your vendors directory, and then adding PhpGacl as a component to your controller), and create AXO groups/AXO objects for each controller/action (see at the bottom of this message) Let me give you a quick view on how you programmatically manipulate your ACL data: // Add groups $this->PhpGacl->saveGroup(1, 'my group #1 with ID 1'); $this->PhpGacl->saveGroup(2, 'my group #1 with ID 2'); // Modify group $this->PhpGacl->saveGroup(2, 'my group #1 with ID 2 with new name'); // Get groups $groups = $this->PhpGacl->getGroups(); /* This gets you a threaded array like: Array ( [0] => Array ( [id] => authenticated [name] => Authenticated ) [1] => Array ( [id] => 2 [name] => my group #1 ) [2] => Array ( [id] => 3 [name] => my group #2 [children] => Array ( [0] => Array ( [id] => 5 [name] => my group #2.1 ) ) ) [3] => Array ( [id] => 4 [name] => my group #3 ) ) */ // Add user: $this->PhpGacl->saveUser(1, 'mariano.iglesias'); // Modify user: $this->PhpGacl->saveUser(1, 'mariano.iglesias (new)'); // Assign groups to user: $this->PhpGacl->assign(1, array(1, 2)); // Get user groups: $this->PhpGacl->getUserGroups(1); /* * This gets you an array like: * * Array * ( *[0] => 1, *[1] => 2, *[2] => authenticated * ) */ // Change user group assignments: $this->PhpGacl->assign(1, array(2, 'authenticated')); /* * After which the previous assigned group #1 will be un-assigned, #2 * will remain assigned, and 'authenticated' will be added to the assignment */ // Delete group (and related data): $this->PhpGacl->delGroup(3); /* * By default if the group has children, they will be added as children * of this group's parent. But if you call it like: * * $this->PhpGacl->delGroup(3, false); * * Then the children will also be deleted. * * Naturally deleting a group means that assignments with this group are * also removed */ // Delete user (and related data): $this->PhpGacl->delUser(1); // Add controller and its actions as AXO objects: $this->PhpGacl->saveController('Posts'); /* * It creates an AXO group called Posts, and assigned to them * one AXO object per action. * * If the controller was already added, only new actions are * added */ Next step I'm working on is the assignment of rules between group -> controller/action, and user -> controller/action. After that wrap phpGACL check, set up a few things, and then release the first version (without the plugin to manipulate data via GUI) -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Integrating phpGACL with CakePHP
Hi Mariano, Absolutly - I've been looking for an ACL solution similar to this. I've had issues with CakePHP's own ACL system, and feel I do need more levels of control. Please keep me informed on your work and I'd be happy to do some testing. -- Tane Piper Personal: http://digitalspaghetti.me.uk Work: http://nohalfmeasures.com This email is: [ ] blogable [ x ] ask first [ ] private Mariano Iglesias wrote: > My fellow bakers, > > As I found myself in the need of having a highly customizable ACL system for > a CakePHP application I'm developing, I'm going ahead with something some > people asked in the past if it could be available. > > The issues with this application that prevented me from using CakePHP's > builtin ACL, which is very strong BTW, were among others: > > 1. I needed a fine grained set of permissions. > 2. I needed AROs to belong to more than one group. > 3. I needed collision handling. > > So I'm now working on a component that provides a wrapper for phpGACL (using > its latest version, 3.3.7), so that it hides the inner complexities of > phpGACL from CakePHP applications. > > I'm setting it up to use the 3D layer system (AROs, ACOs, and AXOs) to allow > greater flexibility (so I can do stuff like: this action can be accessed via > Web, but can't be accessed via RSS for this particular user, interesting > when using CakePHP 1.2 automatic content type management) > > I'm expecting to finish the component tomorrow. The component, as I said, > will be a programmatic wrapper. I'm also planning to build a plugin that'll > offer the manipulation of these permissions, but have yet not established > when I'll start with that. > > Anyway, I've just wanted to drop a note if anyone was looking for the same. > > -MI > > --- > > Remember, smart coders answer ten questions for every question they ask. > So be smart, be cool, and share your knowledge. > > BAKE ON! > > blog: http://www.MarianoIglesias.com.ar > > > > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Integrating phpGACL with CakePHP
Interesting project Mariano. I think it is probably over kill for my needs personally, but hope it works out. It will become one more reason for Cake to be your framework of choice :-) Langdon Mariano Iglesias wrote: > My fellow bakers, > > As I found myself in the need of having a highly customizable ACL system for > a CakePHP application I'm developing, I'm going ahead with something some > people asked in the past if it could be available. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Integrating phpGACL with CakePHP
My fellow bakers, As I found myself in the need of having a highly customizable ACL system for a CakePHP application I'm developing, I'm going ahead with something some people asked in the past if it could be available. The issues with this application that prevented me from using CakePHP's builtin ACL, which is very strong BTW, were among others: 1. I needed a fine grained set of permissions. 2. I needed AROs to belong to more than one group. 3. I needed collision handling. So I'm now working on a component that provides a wrapper for phpGACL (using its latest version, 3.3.7), so that it hides the inner complexities of phpGACL from CakePHP applications. I'm setting it up to use the 3D layer system (AROs, ACOs, and AXOs) to allow greater flexibility (so I can do stuff like: this action can be accessed via Web, but can't be accessed via RSS for this particular user, interesting when using CakePHP 1.2 automatic content type management) I'm expecting to finish the component tomorrow. The component, as I said, will be a programmatic wrapper. I'm also planning to build a plugin that'll offer the manipulation of these permissions, but have yet not established when I'll start with that. Anyway, I've just wanted to drop a note if anyone was looking for the same. -MI --- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---