Aller directement à la fin des métadonnées
Aller au début des métadonnées
CiviCRM Documentation

This is a modification to two civicrm 2.0.4 files used in Joomla 1.5 which allows you to use CiviCRM groups as access control to front end CiviCRM menu items.
(This does not allow to set CiviCRM groups as access control to modules and content JUST front end CiviCRM items.)

As an additional benefit this gives a warning (but does not stop the user proceeding) if the Joomla and CiviCRM email addresses do not match. There may be users who want to use different emails for the website and whatever you are using CiviCRM for.

Be warned - this works with CiviCRM 2.0.2 and Joomla 1.5.3 - I have no idea if it is good for J1.0

The two files you need to modify are civicrm.xml which is found in

and civicrm.php which is found in

The mod to the xml file adds two new parameters when creating or editing a frontend CiviCRM menu entry from the adminstrator backend.
The first parameter allows you to specify a comma separated list of CiviCRM group ids which are allowed to access this menu item. 'public' bypasses the checking and '0' will allow any Joomla user who is also a CiviCRM contact to access.

The second parameter allows you to customise the message that the user sees if they do not have permission.

Here are the files - unzip, rename the originals so you dont loose them, and upload these

Here is the detail of the changes:

In civicrm.xml after about line 28

INSERT the following

This adds the new parameters. For the aclGroups parameter the value 'public' (the default) will bypass any access control. You can of course use the Joomla Access Level public/registered/special to control visibility of the menu item as well. If you put '0' for the group then any registered website user who is also a CiviCRM contact will be able to access the item. Registered users without a matching CiviCRM identity will be barred.

In civicrm.php about line 25 AFTER the line

INSERT the following lines:

then around old line 54 AFTER the lines

and BEFORE the line

INSERT the following lines


Since this only affects the Joomla specific files could it be checked, tested, improved and incorporated as it provides good additional functionality.



Creative Commons License
Except where otherwise noted, content on this site is licensed under a Creative Commons Attribution-Share Alike 3.0 United States Licence.