HTML Logo by World Wide Web Consortium (www.w3.org). Click to learn more about our commitment to accessibility and standards.

Moving forward with Composr

ocPortal has been relaunched as Composr CMS, which is now in beta. ocPortal 9 will be superseded by Composr 10.

Head over to compo.sr for our new site, and to our migration roadmap. Existing ocPortal member accounts have been mirrored.


Administration

Login / Search

 [ Join | More ]
 Add topic 
Posted
Rating:
#25790 (In Topic #6025)
Avatar

Community saint

Does anyone know the path to follow or allow access... I gave a specific user group permissions other than admin or supermod. The only permission this group does not have is changing or editing a members profile. Does anyone know the area in which to access this???
Back to the top
 
Posted
Rating:
#25802
Avatar

Only administrators (and the member themselves) can edit a member's profile, as any case like this where the site owner wants people other than admins to be able to edit member profiles is a one-off.

There is, however, a fairly simple code modification to allow what you want.

Back to the top
 
Posted
Rating:
#25811
Avatar

Community saint

Any helpful hints on where to start?!!

 :|
Back to the top
 
Posted
Rating:
#25813
Avatar

/personalzone/pages/modules/editprofile.php, line 60.

Back to the top
 
Posted
Rating:
#25816
Avatar

Community saint

Thank you.

This is where I started and unless I am supposed to add the code there is nothing in line 60

      $info=array();

      $info['author']='Chris Graham';

      $info['organisation']='ocProducts';

      $info['hacked_by']=NULL;

      $info['hack_version']=NULL;
54
55      $info['version']=2;
56
57      $info['locked']=true;
58
59     return $info;
60
61   }

Thank you for the help…

Back to the top
 
Posted
Rating:
#25820
Avatar

It looks like linebreaks are being interpreted twice, in which case you should look at line 120, which should look as follows:

Code

enforce_personal_access($member_id);

Back to the top
 
Posted
Rating:
#25821
Avatar

Community saint

Ok,

I got this, but I think I am missing something still.

Where it has Member is that the group I want to have permission?
And I am not sure of ?ID_text permission

This is what I have done…… *enforce_personal_access('ranger_admin',$member_id, ?ID_text 'null');


void enforce_personal_access(MEMBER member_id, ?ID_TEXT permission)


Only allow members here that are either the give member, admins, or have a specific permission. All other members come up to an error message wall.

Parameters…

Name member_id
Description The member who typically (i.e. when it's not an administrative override) we want the current member to be.
Type MEMBER

Name permission
Description The overide permission the current member must have (NULL: no general override).
Default value  
Type ?ID_TEXT


Returns…


Back to the top
 
Posted
Rating:
#25822
Avatar

I would actually do something along the lines of only calling the enforce_personal_access call if a check with has_specific_permission_group (from /sources/permissions.php) fails.

Note that PHP is not a strongly-typed language, so you don't need the "?ID_text"s, etc. ;)

Back to the top
 
1 guests and 0 members have just viewed this: None
Control functions:

Quick reply   Contract

Your name:
Your message: