SQL... customizing ACL's in Joomla 1.5??

Discussion in 'Customization & add-ons' started by speakingbadger, Mar 26, 2008.

  1. speakingbadger

    speakingbadger aMember Pro Customer

    Joined:
    Jan 5, 2008
    Messages:
    14
    OK... as a non-programmer that feels like I'm learning Russian all by myself in a matter of days, when I have no clue how to read the Cyrillic alphabet... I'm confused here and my brain is fried, but when you have a small budget, sometimes you end up learning things you didn't think you could...

    So my question that I hope someone who does know what they are doing might know is:

    Currently in Joomla 1.5 there are 7 default levels of access called Access Control Levels (ACL), 4 on the front and 3 on the back. With the amember integration module you can attach and give access to any of those seven levels... but I know from reading in the developers guides that it is possible to have customize ACL's.

    Would you just use this code directly with the MySQL database by using phpmyadmin and modifying it with the proper "parent_name" and the "new_name" of the group you want?? Would this be how you add the new groups?? Is it that simple so to speak...?? Am I off base with thinking this is done directly with the SQL data on the database in order to create the new fields??

    I thought it was already done or integrated somehow, with the module I recently purchased, but it wasn't. Our dilemma is we currently have about 10 different paid membership levels and I would like each membership level to have it's own specific viewable content in Joomla...

    If I do the above, what else would I have to do to make it work with amember??

    Does anyone have any ideas... or is it much, much more difficult to set this up..?? ...and if so, how much would it cost to get someone to do it for me?

    Thanks for any help, advice or thoughts you all might have...

    Justin
    www.alliantnetwork.org
  2. speakingbadger

    speakingbadger aMember Pro Customer

    Joined:
    Jan 5, 2008
    Messages:
    14
    Wow... it actually worked... I had to modify the code a bit, but after a bit of trial and error to find all the right names and such, it actually worked... I successfully created a whole new user group that is showing up in amember and in Joomla... I'm in shock!! :D
  3. speakingbadger

    speakingbadger aMember Pro Customer

    Joined:
    Jan 5, 2008
    Messages:
    14
    But now I have a couple new problems. I feel like I'm having a conversation with myself. But if someone knows an answer, I would be very grateful to hear it.

    I have the new user groups, I've assigned them in amember and now I'm working on how to make the front end talk to the back end. Creating tables is one thing, but making the front talk to the back is a completely different story. Here are my problems and I can't seem to find the solution so far. Perhaps someone else can... because I REALLY NEED HELP on these....

    1. I know this is dangerous water, but in phpMyAdmin, there is a display of all the fields in your database. Now particularly in Joomla, there are fields that start with jos_ and other fields that seem to be the exact same fields just with a different prefix and they start with bak_ does anyone know what the difference is and what specifically does bak_ alter??

    I made my changes to add the fields to the jos_core_acl_aro_groups, but I can make the same changes to bak_core_acl_aro_groups, and I don't see any differences or know what it is doing or if I need to make those changes on both parts of the database. Does anyone know??

    2. Then there seems to be some sort of a limitation in the back office of Joomla, where only 11 or so fields show up from the table. The issue this creates, is two-fold and the first one isn't really serious, because if I'm managing all users through amember, it is OK.. but that is where the second problem comes in and makes this first one very serious. I can't assign or see any backend privileges for admins.

    When I try and assign them through amember, via a special product, the user management section of Joomla doesn't recognize any user that is labeled under the "PublicBackend" user section and then it doesn't list them in Joomla. Does anyone know how to tie the regular admin logins from amember to Joomla..?? Then I wouldn't even be trying what I describe below.

    Since I don't know how to set up admins, I set up a Super Admin account, by creating a new product called "super admin", then I used my test account and made the free purchase through the back end for that access level. Because Super admins are part of the Public Backend, it doesn't show up at all. I would like to have more than just me assigned to admin tasks and the "Super Admin" access that was set up through the Joomla setup is causing database errors that show up for debugging in amember. At least that is where I think the errors are coming from.

    The system wont allow me to logout of Joomla at all now, so I can't even test if it allows a user to log in, even they that user doesn't show up in the settings in Joomla... Yes, I'm logged out of amember too and it still wont let me log out. Maybe if I wait several hours...

    Again, any help in regards to these issues would be greatly appreciated.
    Thanks,
    Justin
    http://alliantnetwork.org
  4. tomfra

    tomfra Member

    Joined:
    Dec 21, 2006
    Messages:
    199
    Justin,

    I kind of think you are trying to reinvent the wheel. No offence, but I am sure someone else has already created a Joomla extension that solves your problem.

    As I said in another post, the Joomla extensions repository at http://extensions.joomla.org may be a good start for the search.

    Tomas
  5. speakingbadger

    speakingbadger aMember Pro Customer

    Joined:
    Jan 5, 2008
    Messages:
    14
    Tomas,

    Thanks for your response... I really appreciate it and I wish you were right. I've been scouring the extensions repository along with the developers sites and forums for days looking for an answer, but so far I haven't found any that will work with amember. I purchased the extension from amember and it was just basic integration. It doesn't have a way to create more product access levels, it just uses the default ones set up. Which for the front end customer are the public front end users: Registered, author, editor and publisher. Those levels of users are only for posting not viewing content.

    For viewing content, there are only three levels: public, registered and special. I still can't figure out how to change those in relation to the levels controlled by amember. I just need a solution that will solve the above and talk with amember.

    So if you or anyone else knows a solution or where a plugin or extension is that solves these problems, then PLEASE tell me where it is...

    Thank you, thank you, thank you... in advance.

    Justin
    www.alliantnetwork.org
  6. hunny

    hunny New Member

    Joined:
    Apr 15, 2009
    Messages:
    2
    Justin, I am hoping you were able to resolve some of your issues? I would like to pick your brain in an attempt to resolve similar problems. I.e. have have followed the steps to create custom user group as per http://www.blog.highub.com/cms/joomla-cms/joomla-add-custom-user-groups/ - Now my problem is: Group only available for selection under menu's AND once set, content is hidden if user is not in the group, but ALSO when the user is in the right group.
  7. hunny

    hunny New Member

    Joined:
    Apr 15, 2009
    Messages:
    2
    Here is a more detailed explanation of my problem
    I’m running joomla 1.5.9 under windows(test version)linux(production).
    This is what I’ve done on my test windows box

    1. edited line 113 of \administrator\components\com_users\views\user\view.html.php, changing
    from : $gtree = $acl->get_group_children_tree( null, 'USERS', false);
    to : $gtree = $acl->get_group_children_tree( null, 'USERS', true );

    2. I added new group to jos_core_acl_aro_groups, say NGrp, parent_id=18 as Registered group’s id=18. I got NGrp’s id=31

    3. I run rebuild.php and got lft=12, rgt=13 for NGrp group

    4. I added NGrp to jos_groups, id=3, name=NGrp

    5. I created new user, say NUser and assigned it to NGrp group. NGrp group which, based on the visual clues of the select , is at the same level as Author group??
    -*Users
    ******* Public Front-end
    ******.*-*Registered
    ******.********Author
    ******.*******.*-*Editor
    ******.*******.*******-*Publisher
    ******.*******-*NGrp
    ******-* Public Back-end
    ************-*Manager
    ******************-*Administrator
    ************************-*Super Administrator

    6. The NGrp only appears as selectable under Menus ?? (can live with this unless anyone can suggest a solution?)
    Changed access of an existing menu item, say Nmenu from Registered to NGrp

    8. Logged in as NUser, I went to click on the Nmenu item- it's not visible to me (or any other type of user - not even publisher)

    Well, something is wrong… The question is, what am I doing wrong?
    AND what is the function of lft and rgt in the jos_core_acl_aro_groups table?

Share This Page